(event_loop, api_v2_client, test_operation, test_agent, test_ability,
active_link, finished_link, expected_link_output)
| 584 | |
| 585 | @pytest.fixture |
| 586 | def setup_operations_api_test(event_loop, api_v2_client, test_operation, test_agent, test_ability, |
| 587 | active_link, finished_link, expected_link_output): |
| 588 | test_operation = OperationSchema().load(test_operation) |
| 589 | test_operation.agents.append(test_agent) |
| 590 | test_operation.set_start_details() |
| 591 | test_link = Link.load(active_link) |
| 592 | test_link.host = test_agent.host |
| 593 | finished_link = Link.load(finished_link) |
| 594 | finished_link.output = expected_link_output |
| 595 | finished_link.host = test_agent.host |
| 596 | test_operation.chain.append(test_link) |
| 597 | test_operation.chain.append(finished_link) |
| 598 | test_objective = Objective(id='123', name='test objective', description='test', goals=[]) |
| 599 | test_operation.objective = test_objective |
| 600 | event_loop.run_until_complete(BaseService.get_service('data_svc').store(test_operation)) |
| 601 | |
| 602 | |
| 603 | @pytest.fixture |
nothing calls this directly
no test coverage detected