Skip to content
Snippets Groups Projects
Commit 1d292351 authored by rha104's avatar rha104
Browse files

Fixed tests

parent 4840bd32
No related branches found
No related tags found
No related merge requests found
Pipeline #74965 passed
......@@ -298,8 +298,8 @@ def test_successfully_post_batch_with_voucher(client, batch_with_voucher_fixture
batch = Batch.from_dict(batch_with_voucher_fixture)
requests_mock.post(url, json={'somestatus': 'ok'}, status_code=200, request_headers={"Content-Type": "application/json"})
response = client.post_new_batch(batch) # we only get json back
assert response == {'somestatus': 'ok'}
response = client.post_new_batch(batch) # we get a response object back
assert response.json() == {'somestatus': 'ok'}
def test_successfully_post_batch_with_voucher_and_response(client, batch_with_voucher_fixture, requests_mock, baseurl):
......@@ -309,7 +309,7 @@ def test_successfully_post_batch_with_voucher_and_response(client, batch_with_vo
requests_mock.post(url, json={'somestatus': 'ok'}, status_code=200, request_headers={"Content-Type": "application/json"}) #expect json content
batch = Batch.from_dict(batch_with_voucher_fixture)
response = client.post_new_batch(batch, return_response=True) # we get a response back
response = client.post_new_batch(batch) # we get a response object back
assert response.json() == {'somestatus': 'ok'}
assert response.status_code == 200
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment