Complete the code to define the type of test that checks individual functions in isolation.
def test_user_creation(): # This is a [1] test assert create_user('Alice') == 'User Alice created'
A unit test checks a small part of the code, like a single function, in isolation.
Complete the code to specify the test type that verifies communication between microservices.
def test_order_processing(): # This is an [1] test response = call_payment_service(order_id) assert response.status == 'success'
An integration test checks how different parts or services work together.
Fix the error in the test type that checks the entire system's behavior from the user's perspective.
def test_full_system(): # This is a [1] test result = simulate_user_journey() assert result == 'success'
A system test verifies the complete system's behavior as a whole.
Fill both blanks to complete the test strategy for microservices: use {{BLANK_1}} tests for individual services and {{BLANK_2}} tests for service interactions.
testing_strategy = {
'single_service': '[1]',
'service_interaction': '[2]'
}Unit tests check individual services, while integration tests check how services work together.
Fill all three blanks to complete the testing pyramid: {{BLANK_1}} tests form the base, {{BLANK_2}} tests are in the middle, and {{BLANK_3}} tests are at the top.
testing_pyramid = ['[1]', '[2]', '[3]']
The testing pyramid has unit tests at the base, integration tests in the middle, and system tests at the top.