Skip to content

Commit

Permalink
Handle earthaccess returning full file paths
Browse files Browse the repository at this point in the history
Relates #34
  • Loading branch information
giorgiobasile committed Nov 1, 2023
1 parent 90de0e2 commit 4c7f365
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
prefect>=2.0.0
earthaccess
earthaccess>=0.7.0
8 changes: 6 additions & 2 deletions tests/test_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,12 @@ def test_flow(download_path):

with TemporaryDirectory() as temp_dir:
with prefect_test_harness():
exp_files = [temp_dir + "/ATL08_20181105083647_05760107_005_01.h5"]

granules, files = test_flow(temp_dir)
assert isinstance(granules, list)
assert len(granules) == 1
assert files == ["ATL08_20181105083647_05760107_005_01.h5"]
assert Path(temp_dir, "ATL08_20181105083647_05760107_005_01.h5").exists()

assert files == exp_files
for file in exp_files:
assert Path(file).exists()

0 comments on commit 4c7f365

Please sign in to comment.