MCPcopy
hub / github.com/treeverse/dvc / test_pull_partial_import_missing

Function test_pull_partial_import_missing

tests/func/test_data_cloud.py:298–307  ·  view source on GitHub ↗
(tmp_dir, dvc, local_workspace)

Source from the content-addressed store, hash-verified

296
297
298def test_pull_partial_import_missing(tmp_dir, dvc, local_workspace):
299 local_workspace.gen("file", "file content")
300 dst = tmp_dir / "file"
301 dvc.imp_url("remote://workspace/file", os.fspath(dst), no_download=True)
302
303 (local_workspace / "file").unlink()
304 with pytest.raises(CheckoutError) as exc:
305 dvc.pull("file")
306 assert exc.value.result == empty_pull | {"failed": ["file"]}
307 assert not dst.exists()
308
309
310def test_pull_partial_import_modified(tmp_dir, dvc, local_workspace):

Callers

nothing calls this directly

Calls 5

unlinkMethod · 0.80
genMethod · 0.45
fspathMethod · 0.45
pullMethod · 0.45
existsMethod · 0.45

Tested by

no test coverage detected