Skip to content

Commit

Permalink
Merge pull request #496 from iotaledger/fix/update_error_message_chec…
Browse files Browse the repository at this point in the history
…king

(Testing): Update error message checking
  • Loading branch information
bingyanglin authored Apr 13, 2021
2 parents 5947f6d + c973e53 commit 1446775
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions bindings/python/native/tests/test_full_node_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ def test_get_health():

def test_get_info():
node_info = client.get_info()
assert isinstance(node_info, dict) and 'is_healthy' in node_info['nodeinfo']
assert isinstance(
node_info, dict) and 'is_healthy' in node_info['nodeinfo']


def test_get_peers():
Expand All @@ -30,7 +31,7 @@ def test_get_peers():
assert isinstance(peers, list)
except ValueError as e:
# Else the error must be access forbidden
assert "access forbidden, error: forbidden" in str(e)
assert "Forbidden" in str(e)


def test_get_tips():
Expand Down Expand Up @@ -95,7 +96,7 @@ def test_get_receipts():
assert isinstance(receipt, list)
except ValueError as e:
# Else the error must be access forbidden
assert "access forbidden, error: forbidden" in str(e)
assert "Forbidden" in str(e)


def test_get_receipts_migrated_at():
Expand All @@ -105,7 +106,7 @@ def test_get_receipts_migrated_at():
assert isinstance(receipts, list)
except ValueError as e:
# Else the error must be access forbidden
assert "access forbidden, error: forbidden" in str(e)
assert "Forbidden" in str(e)


def test_get_treasury():
Expand Down

0 comments on commit 1446775

Please sign in to comment.