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

Method test_force

tests/func/test_checkout.py:145–151  ·  view source on GitHub ↗
(self, mocker, tmp_dir, dvc)

Source from the content-addressed store, hash-verified

143 assert not (tmp_dir / "data" / "not_cached.txt").exists()
144
145 def test_force(self, mocker, tmp_dir, dvc):
146 (stage,) = tmp_dir.dvc_gen("data", {"foo": "foo"})
147
148 # change working directory
149 (tmp_dir / "data").gen("not_cached.txt", "not_cached")
150 assert main(["checkout", stage.relpath]) != 0
151 assert (tmp_dir / "data" / "not_cached.txt").exists()
152
153
154def test_checkout_selective_remove(tmp_dir, dvc):

Callers

nothing calls this directly

Calls 4

mainFunction · 0.90
dvc_genMethod · 0.80
genMethod · 0.45
existsMethod · 0.45

Tested by

no test coverage detected