Skip to content

Commit

Permalink
Merge branch 'master' of github.com:odd-industries/dvc
Browse files Browse the repository at this point in the history
  • Loading branch information
verasativa committed Dec 5, 2019
2 parents a0f1869 + 4e53f17 commit 2ea4d26
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion tests/unit/remote/test_remote_dir.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,4 +141,12 @@ def test_download_dir(remote, tmpdir):
to_info = os.PathInfo(path)
remote.download(remote.path_info / "data", to_info)
assert os.path.isdir(path)
# check the list of files
data_dir = tmpdir / "data"
assert len(list(walk_files(path, None))) == 7
assert (data_dir / "alice").read_text(encoding="utf-8") == "alice"
assert (data_dir / "alpha").read_text(encoding="utf-8") == "alpha"
assert (data_dir / "subdir-file.txt").read_text(encoding="utf-8") == "subdir"
assert (data_dir / "subdir" / "1").read_text(encoding="utf-8") == "1"
assert (data_dir / "subdir" / "2").read_text(encoding="utf-8") == "2"
assert (data_dir / "subdir" / "3").read_text(encoding="utf-8") == "3"
assert (data_dir / "subdir" / "empty_file").read_text(encoding="utf-8") == ""

0 comments on commit 2ea4d26

Please sign in to comment.