Skip to content

Commit

Permalink
better approach
Browse files Browse the repository at this point in the history
  • Loading branch information
lizgehret committed Oct 17, 2024
1 parent a52890e commit 6c1fca3
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion rescript/tests/test_ncbi.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,16 @@ def test_ncbi_fails(self):
'o__Boletales; f__Boletaceae; g__Boletus; s__edulis'
)
exp_log_segment = 'Retrying'
self.assertTrue(exp_log_segment in line for line in log.output)
for line in log.output:
if exp_log_segment in line:
result = True
break
else:
result = False
self.assertTrue(
result,
f'`{exp_log_segment}` not found in the output log.'
)

def test_get_ncbi_dirty_tricks(self):
with self.assertLogs(level='WARNING') as log:
Expand Down

0 comments on commit 6c1fca3

Please sign in to comment.