Skip to content

Commit 9f63173

Browse files
Update tests to work with fixtures with less timesteps
1 parent bfa83e4 commit 9f63173

2 files changed

Lines changed: 10 additions & 10 deletions

File tree

imod/tests/test_mf6/test_mf6_out.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ def test_open_cbc__dis_transient(transient_twri_result):
222222
"wel",
223223
]
224224
for array in cbc.values():
225-
assert array.shape == (30, 3, 15, 15)
225+
assert array.shape == (2, 3, 15, 15)
226226
assert isinstance(array, xr.DataArray)
227227
assert isinstance(array.data, dask.array.Array)
228228

@@ -266,7 +266,7 @@ def test_open_cbc__dis_transient_unconfined(transient_unconfined_twri_result):
266266
"wel",
267267
]
268268
for array in cbc.values():
269-
assert array.shape == (30, 3, 15, 15)
269+
assert array.shape == (2, 3, 15, 15)
270270
assert isinstance(array, xr.DataArray)
271271
assert isinstance(array.data, dask.array.Array)
272272

@@ -289,10 +289,10 @@ def test_open_cbc__disv(circle_result):
289289
]
290290
for key, array in cbc.items():
291291
if key in ("chd", "flow-lower-face"):
292-
assert array.shape == (52, 2, 216)
292+
assert array.shape == (2, 2, 216)
293293
assert array.dims[-1] == array.ugrid.grid.face_dimension
294294
else:
295-
assert array.shape == (52, 2, 342)
295+
assert array.shape == (2, 2, 342)
296296
assert array.dims[-1] == array.ugrid.grid.edge_dimension
297297
assert isinstance(array, xu.UgridDataArray)
298298
assert isinstance(array.data, dask.array.Array)
@@ -333,10 +333,10 @@ def test_open_cbc__disv_sto(circle_result_sto):
333333
]
334334
for key, array in cbc.items():
335335
if key in ("chd", "flow-lower-face", "sto-ss"):
336-
assert array.shape == (52, 2, 216)
336+
assert array.shape == (2, 2, 216)
337337
assert array.dims[-1] == array.ugrid.grid.face_dimension
338338
else:
339-
assert array.shape == (52, 2, 342)
339+
assert array.shape == (2, 2, 342)
340340
assert array.dims[-1] == array.ugrid.grid.edge_dimension
341341
assert isinstance(array, xu.UgridDataArray)
342342
assert isinstance(array.data, dask.array.Array)

imod/tests/test_mf6/test_mf6_simulation.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,15 +71,15 @@ def test_simulation_open_head(circle_model, tmp_path):
7171

7272
assert isinstance(head_notime, xu.UgridDataArray)
7373
assert head_notime.dims == ("time", "layer", "mesh2d_nFaces")
74-
assert head_notime.shape == (52, 2, 216)
74+
assert head_notime.shape == (2, 2, 216)
7575

7676
# open heads with time conversion.
7777
head = simulation.open_head(
7878
simulation_start_time=datetime(2013, 3, 11, 22, 0, 0), time_unit="w"
7979
)
8080
assert head.dims == ("time", "layer", "mesh2d_nFaces")
81-
assert head.shape == (52, 2, 216)
82-
assert str(head.coords["time"].values[()][0]) == "2013-04-29T22:00:00.000000000"
81+
assert head.shape == (2, 2, 216)
82+
assert str(head.coords["time"].values[()][0]) == "2013-03-18T22:00:00.000000000"
8383

8484

8585
@pytest.mark.usefixtures("circle_model")
@@ -100,7 +100,7 @@ def test_simulation_open_head_relative_path(circle_model, tmp_path):
100100

101101
assert isinstance(head, xu.UgridDataArray)
102102
assert head.dims == ("time", "layer", "mesh2d_nFaces")
103-
assert head.shape == (52, 2, 216)
103+
assert head.shape == (2, 2, 216)
104104

105105

106106
@pytest.mark.usefixtures("circle_model")

0 commit comments

Comments
 (0)