Skip to content

Commit 986ff7a

Browse files
committed
[release/2024-10-14] fix-forward: fix search test
1 parent 608cf34 commit 986ff7a

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

src/api/searchCpmProduct/tests/test_index.py

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -160,15 +160,14 @@ def test_index_no_such_product_team():
160160
)
161161

162162
result_body = json_loads(result["body"])
163-
assert result["statusCode"] == 404
164-
assert result_body["resourceType"] == "OperationOutcome"
165-
assert (
166-
result_body["issue"][0]["details"]["coding"][0]["code"] == "RESOURCE_NOT_FOUND"
167-
)
168-
assert (
169-
result_body["issue"][0]["diagnostics"]
170-
== "Could not find ProductTeam for key ('123456')"
171-
)
163+
assert result_body == {
164+
"errors": [
165+
{
166+
"code": "RESOURCE_NOT_FOUND",
167+
"message": "Could not find ProductTeam for key ('123456')",
168+
}
169+
]
170+
}
172171

173172

174173
@pytest.mark.integration

0 commit comments

Comments
 (0)