Skip to content

Commit 8250530

Browse files
committed
NRL-525 fix link matching in integration tests using relative urls
1 parent d100883 commit 8250530

File tree

1 file changed

+10
-16
lines changed

1 file changed

+10
-16
lines changed

tests/features/steps/3_assert.py

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -89,25 +89,19 @@ def assert_bundle_self(context: Context, rel_url: str):
8989
)
9090

9191
link_entry = context.bundle.link[0].dict(exclude_none=True)
92-
assert (
93-
link_entry.get("relation") == "self",
94-
format_error(
95-
"Link should specify a 'self' type relation",
96-
"self",
97-
link_entry.get("relation"),
98-
context.response.text,
99-
),
92+
assert link_entry.get("relation") == "self", format_error(
93+
"Link should specify a 'self' type relation",
94+
"self",
95+
link_entry.get("relation"),
96+
context.response.text,
10097
)
10198

10299
actual_url_params = link_entry.get("url").split("consumer/FHIR/R4/")[-1]
103-
assert (
104-
actual_url_params == "self",
105-
format_error(
106-
"Link url does not specify the search parameters expected",
107-
rel_url,
108-
actual_url_params,
109-
context.response.text,
110-
),
100+
assert actual_url_params == "self", format_error(
101+
"Link url does not specify the search parameters expected",
102+
rel_url,
103+
actual_url_params,
104+
context.response.text,
111105
)
112106

113107

0 commit comments

Comments
 (0)