Skip to content

Commit

Permalink
tests: fix get_links and query tests
Browse files Browse the repository at this point in the history
* Remove template from get_links and query
* Show the expected and response body in the tests
  • Loading branch information
levisingularity committed Jan 23, 2024
1 parent 9298fb9 commit 691f06e
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def unknown_action_event(self):
def assert_successful_execution(self, valid_event, expected_output):
response = handle(valid_event, context={})
assert response["statusCode"] == 200
assert response["body"] == json.dumps(expected_output)
assert response["body"] == json.dumps(expected_output), f"Assertion failed:\nResponse Body: {response['body']}\nExpected: {json.dumps(expected_output)}"

def assert_payload_malformed(self, malformed_event):
response = handle(malformed_event, context={})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ def expected_output(self):
{
"handle": "ee1c03e6d1f104ccd811cfbba018451a",
"type": "Inheritance",
"template": ["Inheritance", "Concept", "Concept"],
"targets": [
"4e8e26e3276af8a5c2ac2cc2dc95c6d2",
"80aff30094874e75028033a38ce677bb",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ def expected_output(self):
{
"handle": "bad7472f41a0e7d601ca294eb4607c3a",
"type": "Similarity",
"template": ["Similarity", "Concept", "Concept"],
"targets": [
{
"handle": "af12f10f9ae2002a1607ba0b47ba8407",
Expand Down

0 comments on commit 691f06e

Please sign in to comment.