Skip to content

Commit

Permalink
make var name more transparent
Browse files Browse the repository at this point in the history
  • Loading branch information
esoteric-ephemera committed May 22, 2024
1 parent c1f6b27 commit 5166419
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def get_gzip_or_unzipped(test_file_or_dir: str) -> str:
if os.path.isdir(test_file_or_dir):
return test_file_or_dir

for file_to_test in [test_file_or_dir, test_file_or_dir.split(".gz")[0], test_file_or_dir.split(".GZ")[0]]:
if os.path.isfile(file_to_test):
return file_to_test
for file_name in [test_file_or_dir, test_file_or_dir.split(".gz")[0], test_file_or_dir.split(".GZ")[0]]:
if os.path.isfile(file_name):
return file_name
raise FileNotFoundError(f"Cannot find {test_file_or_dir}")

0 comments on commit 5166419

Please sign in to comment.