MCPcopy
hub / github.com/mne-tools/mne-python / test_datasets

Function test_datasets

mne/utils/tests/test_testing.py:43–53  ·  view source on GitHub ↗

Test dataset config.

(monkeypatch, tmp_path)

Source from the content-addressed store, hash-verified

41
42
43def test_datasets(monkeypatch, tmp_path):
44 """Test dataset config."""
45 # gh-4192
46 fake_path = tmp_path / "MNE-testing-data"
47 fake_path.mkdir()
48 with open(fake_path / "version.txt", "w") as fid:
49 fid.write("9999.9999")
50 monkeypatch.setenv("_MNE_FAKE_HOME_DIR", str(tmp_path))
51 monkeypatch.setenv("MNE_DATASETS_TESTING_PATH", str(tmp_path))
52 got_path = str(testing.data_path(download=False, verbose="debug"))
53 assert got_path == str(fake_path)
54
55
56def test_url_to_local_path():

Callers

nothing calls this directly

Calls 1

writeMethod · 0.80

Tested by

no test coverage detected