Skip to content

Commit

Permalink
TST: for completeness' sake, test str(<= 0) limits
Browse files Browse the repository at this point in the history
  • Loading branch information
fedarko committed Sep 11, 2019
1 parent 9403705 commit c0db25b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions labcontrol/db/tests/test_study.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,10 @@ def test_samples_with_limit(self):
ValueError, "limit must be greater than zero"
):
s.samples(limit=i)
with self.assertRaisesRegex(
ValueError, "limit must be greater than zero"
):
s.samples(limit=str(i))

# Check evil corner case where the limit is nonpositive and not
# castable to an int (this should fail first on the castable check)
Expand Down

0 comments on commit c0db25b

Please sign in to comment.