def _verify_restapi_results(self, driver_result):
posts = <NUM_LIT:0><EOL>deletes = <NUM_LIT:0><EOL>for idx in range(<NUM_LIT:0>, len(driver_result)):<EOL><INDENT>if driver_result[idx][<NUM_LIT:3>] == POST:<EOL><INDENT>posts += <NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>deletes += <NUM_LIT:1><EOL><DEDENT><DEDENT>self.assertEqual(<EOL>posts,<EOL>len(self.mock_driver.rest_post.mock_calls),<EOL>"<STR_LIT>")<EOL>self.assertEqual(<EOL>deletes,<EOL>len(self.mock_driver.rest_delete.mock_calls),<EOL>"<STR_LIT>")<EOL>post_calls = self.mock_driver.rest_post.mock_calls<EOL>del_calls = self.mock_driver.rest_delete.mock_calls<EOL>posts = <NUM_LIT:0><EOL>deletes = <NUM_LIT:0><EOL>for idx in range(<NUM_LIT:0>, len(driver_result)):<EOL><INDENT>if not driver_result[idx]:<EOL><INDENT>continue<EOL><DEDENT>if driver_result[idx][<NUM_LIT:3>] == POST:<EOL><INDENT>test_it = post_calls[posts][<NUM_LIT:1>]<EOL><DEDENT>else:<EOL><INDENT>test_it = del_calls[deletes][<NUM_LIT:1>]<EOL><DEDENT>self.assertTrue(<EOL>(driver_result[idx][<NUM_LIT:0>] ==<EOL>test_it[<NUM_LIT:0>]),<EOL>"<STR_LIT>")<EOL>if driver_result[idx][<NUM_LIT:1>] is not None:<EOL><INDENT>self.assertTrue(<EOL>(driver_result[idx][<NUM_LIT:1>] ==<EOL>test_it[<NUM_LIT:1>]),<EOL>"<STR_LIT>")<EOL><DEDENT>if driver_result[idx][<NUM_LIT:3>] == POST:<EOL><INDENT>self.assertTrue(<EOL>(driver_result[idx][<NUM_LIT:2>] ==<EOL>test_it[<NUM_LIT:2>]),<EOL>"<STR_LIT>")<EOL>posts += <NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>deletes += <NUM_LIT:1><EOL><DEDENT><DEDENT>
Verifies correct entries sent to Nexus.