MCPcopy
hub / github.com/pydata/xarray / test_append_with_mode_rplus_fails

Method test_append_with_mode_rplus_fails

xarray/tests/test_backends.py:3217–3225  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

3215 assert_identical(actual, modified)
3216
3217 def test_append_with_mode_rplus_fails(self) -> None:
3218 original = Dataset({"foo": ("x", [1])})
3219 modified = Dataset({"bar": ("x", [2])})
3220 with self.create_zarr_target() as store:
3221 original.to_zarr(store, **self.version_kwargs)
3222 with pytest.raises(
3223 ValueError, match="dataset contains non-pre-existing variables"
3224 ):
3225 modified.to_zarr(store, mode="r+", **self.version_kwargs)
3226
3227 def test_append_with_invalid_dim_raises(self) -> None:
3228 ds, ds_to_append, _ = create_append_test_data()

Callers

nothing calls this directly

Calls 3

create_zarr_targetMethod · 0.95
to_zarrMethod · 0.95
DatasetClass · 0.90

Tested by

no test coverage detected