DRAG DROP
-
Drag and drop the code snippets from the bottom onto the blanks in the Python script to construct a unit test that checks the API response. Not all options are used.

DRAG DROP
-
Drag and drop the code snippets from the bottom onto the blanks in the Python script to construct a unit test that checks the API response. Not all options are used.
Thats correct: Explanation of the Correct Answers: Blank 1: resp.status_code Retrieves the HTTP status code from the API response to ensure the request was successful (200 OK). Blank 2: resp.content_type Checks that the response content type is application/json, confirming that the API returns data in the expected format. Blank 3: self.assertTrue Verifies that exactly one object is present in the API response (ensuring correct retrieval by ID).