Skip to content

Commit

Permalink
Assert numer of fasta files in a smarter way
Browse files Browse the repository at this point in the history
  • Loading branch information
finngl committed Nov 22, 2023
1 parent 06dc56a commit 3e7fa76
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/test_simple.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,11 @@ def test_pipeline(self):
os.makedirs(self.test_dir)
input_dir = pathlib.Path(self.bifrost_install_dir, 'bifrost', 'test_data', 'samples')
assert(input_dir.exists())
fasta_filenames = input_dir.glob("*.fasta")
file_number = 0
for filename in fasta_filenames:
file_number += 1
child: pathlib.Path
for child in input_dir.iterdir():
if child.is_file() and child.name.endswith('.fasta'):
file_number += 1
assert(file_number == 1)
test_args = ["--sample_name", "SRR2094561", "--outdir", self.test_dir]
launcher.main(args=test_args)
Expand Down

0 comments on commit 3e7fa76

Please sign in to comment.