()
| 8243 | |
| 8244 | |
| 8245 | def test_deepcopy_recursive() -> None: |
| 8246 | # GH:issue:7111 |
| 8247 | |
| 8248 | # direct recursion |
| 8249 | ds = xr.Dataset({"a": (["x"], [1, 2])}) |
| 8250 | ds.attrs["other"] = ds |
| 8251 | |
| 8252 | # TODO: cannot use assert_identical on recursive Vars yet... |
| 8253 | # lets just ensure that deep copy works without RecursionError |
| 8254 | ds.copy(deep=True) |
| 8255 | |
| 8256 | # indirect recursion |
| 8257 | ds2 = xr.Dataset({"b": (["y"], [3, 4])}) |
| 8258 | ds.attrs["other"] = ds2 |
| 8259 | ds2.attrs["other"] = ds |
| 8260 | |
| 8261 | # TODO: cannot use assert_identical on recursive Vars yet... |
| 8262 | # lets just ensure that deep copy works without RecursionError |
| 8263 | ds.copy(deep=True) |
| 8264 | ds2.copy(deep=True) |
| 8265 | |
| 8266 | |
| 8267 | def test_clip(ds) -> None: |
nothing calls this directly
no test coverage detected
searching dependent graphs…