Skip to content

Commit 10c4168

Browse files
committed
fixed test
1 parent 4722a4e commit 10c4168

File tree

1 file changed

+6
-9
lines changed

1 file changed

+6
-9
lines changed

services/director-v2/tests/unit/with_dbs/comp_scheduler/test_api_route_computations.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,11 @@ def _mocked_services_details(
258258
).isoformat()
259259
}
260260

261-
data = {**ServiceGet.model_config["json_schema_extra"]["examples"][0], **data_published, **deprecated} # type: ignore
261+
data = {
262+
**ServiceGet.model_config["json_schema_extra"]["examples"][0],
263+
**data_published,
264+
**deprecated,
265+
} # type: ignore
262266

263267
payload = ServiceGet.model_validate(data)
264268

@@ -354,7 +358,6 @@ def _mocked_get_pricing_unit(request, pricing_plan_id: int) -> httpx.Response:
354358
assert_all_called=False,
355359
assert_all_mocked=True,
356360
) as respx_mock:
357-
358361
respx_mock.get(
359362
re.compile(
360363
r"services/(?P<service_key>simcore/services/(comp|dynamic|frontend)/[^/]+)/(?P<service_version>[^\.]+.[^\.]+.[^/\?]+)/pricing-plan.+"
@@ -915,13 +918,7 @@ async def test_get_computation_from_not_started_computation_task(
915918
stopped=None,
916919
submitted=None,
917920
)
918-
_CHANGED_FIELDS = {"submitted"}
919-
assert returned_computation.model_dump(
920-
exclude=_CHANGED_FIELDS
921-
) == expected_computation.model_dump(exclude=_CHANGED_FIELDS)
922-
assert returned_computation.model_dump(
923-
include=_CHANGED_FIELDS
924-
) != expected_computation.model_dump(include=_CHANGED_FIELDS)
921+
assert returned_computation == expected_computation
925922

926923

927924
async def test_get_computation_from_published_computation_task(

0 commit comments

Comments
 (0)