From 59e6befbfb889f4b1d8e0be096930a90358d521c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrgen=20Eckel?= Date: Wed, 25 Jan 2023 16:50:23 +0100 Subject: [PATCH] fixed error checking MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jürgen Eckel --- tests/web/test_transactions.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/web/test_transactions.py b/tests/web/test_transactions.py index 765d021..83925c1 100644 --- a/tests/web/test_transactions.py +++ b/tests/web/test_transactions.py @@ -481,6 +481,8 @@ def test_post_transaction_compose_valid( client): tx = Create.generate([alice.public_key], [([alice.public_key], 1)], assets=[{"data":"QmW5GVMW98D3mktSDfWHS8nX2UiCd8gP1uCiujnFX4yK97"}]).sign([alice.private_key]) mode_endpoint = TX_ENDPOINT + mode[0] response = client.post(mode_endpoint, data=json.dumps(tx.to_dict())) + assert "202 ACCEPTED" in response.status + tx = tx.to_dict() compose_asset_cid = "QmW5GVMW98D3mktSDfWHS8nX2UiCd8gP1uCiujnFX4yK8n" @@ -502,6 +504,6 @@ def test_post_transaction_compose_valid( client): signed_tx = compose_transaction.sign( [alice.private_key]) mode_endpoint = TX_ENDPOINT + "?mode=commit" response = client.post(mode_endpoint, data=json.dumps(signed_tx.to_dict())) - assert "400 BAD REQUEST" in response.status + assert "202 ACCEPTED" in response.status