def test_push_dataset_creates_parquet_file_in_cloud(repo, upstream, new_dataset): repo.push_dataset(new_dataset) new_dvc_file = repo.repo_dir / (new_dataset.identifier + '.parquet.dvc') assert upstream.cloud_contains_data_for_dvc_file(new_dvc_file)
def test_push_dataset_creates_dvc_file_in_upstream_repo( repo, upstream, new_dataset): new_dvc_file = new_dataset.identifier + '.parquet.dvc' assert not upstream.repo_contains(new_dvc_file) repo.push_dataset(new_dataset) assert upstream.repo_contains(new_dvc_file)
def test_push_dataset_creates_parquet_file_in_cache(repo, cache, new_dataset): new_parquet_file = new_dataset.identifier + '.parquet' assert new_parquet_file not in cache repo.push_dataset(new_dataset) assert new_parquet_file in cache
def test_push_dataset_fails_if_stage_nonempty(repo, new_dataset): repo.add(new_dataset) with pytest.raises(ValueError): repo.push_dataset(new_dataset)