Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_api(self):
httpretty.register_uri(
httpretty.POST,
'http://api.barium.cc/jobs',
body='{"message":"Resource creation started",'
'"url":"http://barium.cc/jobs/5722"}'
)
response = api.post(
url=Arguments.url,
repo_token=Arguments.repo_token,
service_job_id=Arguments.service_job_id,
service_name=Arguments.service_name,
git={},
cc_data={}
)
self.assertEqual(response.json(),
{'url': 'http://barium.cc/jobs/5722',
'message': 'Resource creation started'})