Added test for negative condition
@@ -345,6 +345,19 @@ def test_chunks_distributed_locking(
)
+def test_no_consolidate_dimension_coordinates(netCDFtoZarr_recipe):
+ RecipeClass, file_pattern, kwargs, ds_expected, target = netCDFtoZarr_recipe
+
+ rec = RecipeClass(file_pattern, **kwargs)
+ rec.consolidate_dimension_coordinates = False
+ rec.to_function()()
+ ds_actual = xr.open_zarr(target.get_mapper()).load()
+ xr.testing.assert_identical(ds_actual, ds_expected)
+
+ store = zarr.open_consolidated(target.get_mapper())
+ assert store["time"].chunks == (file_pattern.nitems_per_input["time"],)
+
+
def test_lock_timeout(netCDFtoZarr_recipe_sequential_only, execute_recipe_no_dask):
RecipeClass, file_pattern, kwargs, ds_expected, target = netCDFtoZarr_recipe_sequential_only
