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

Method test_download_from_github

xarray/tests/test_tutorial.py:25–29  ·  view source on GitHub ↗
(self, tmp_path)

Source from the content-addressed store, hash-verified

23@network
24class TestLoadDataTree:
25 def test_download_from_github(self, tmp_path) -> None:
26 cache_dir = tmp_path / tutorial._default_cache_dir_name
27 ds = tutorial.load_datatree("tiny", cache_dir=cache_dir)
28 tiny = DataTree.from_dict({"/": DataArray(range(5), name="tiny").to_dataset()})
29 assert_identical(ds, tiny)
30
31 def test_download_from_github_load_without_cache(self, tmp_path) -> None:
32 cache_dir = tmp_path / tutorial._default_cache_dir_name

Callers

nothing calls this directly

Calls 4

DataArrayClass · 0.90
assert_identicalFunction · 0.90
from_dictMethod · 0.45
to_datasetMethod · 0.45

Tested by

no test coverage detected