MCPcopy Index your code
hub / github.com/numpy/numpy / test_ValidFile

Method test_ValidFile

numpy/lib/tests/test__datasource.py:168–177  ·  view source on GitHub ↗
(self, tmp_path)

Source from the content-addressed store, hash-verified

166 assert_equal(ds.exists(invalid_httpurl()), False)
167
168 def test_ValidFile(self, tmp_path):
169 # Test valid file in destpath
170 ds = datasource.DataSource(tmp_path)
171 tmpfile = valid_textfile(tmp_path)
172 assert_(ds.exists(tmpfile))
173 # Test valid local file not in destpath
174 localdir = mkdtemp()
175 tmpfile = valid_textfile(localdir)
176 assert_(ds.exists(tmpfile))
177 rmtree(localdir)
178
179 def test_InvalidFile(self, tmp_path):
180 ds = datasource.DataSource(tmp_path)

Callers

nothing calls this directly

Calls 3

existsMethod · 0.95
assert_Function · 0.90
valid_textfileFunction · 0.85

Tested by

no test coverage detected