Skip to content

Commit

Permalink
Comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Nikolaos Schoinas committed Nov 10, 2020
1 parent b1b881d commit 59c6e6b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion week05-testing/test_times.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def test_time_goes_backwards(): # this is the negative test
with pytest.raises(ValueError):
time_range("2010-01-12 10:15:00","2010-01-12 10:00:00")

#a parametrised test. This saves time and code
# parametrised test. This saves time and code
@pytest.mark.parametrize("test_input,expected",[('compute_overlap_time(time_range("2010-01-12 10:00:00", "2010-01-12 10:30:00"),time_range("2010-01-12 11:30:00", "2010-01-12 12:00:00"))',[])
,('compute_overlap_time(time_range("2010-01-12 10:00:00", "2010-01-12 12:00:00",8),time_range("2010-01-12 10:30:00", "2010-01-12 11:00:00",2))',[('2010-01-12 10:30:00', '2010-01-12 10:45:00'), ('2010-01-12 10:45:00', '2010-01-12 11:00:00')])
,('compute_overlap_time(time_range("2010-01-12 10:00:00", "2010-01-12 10:30:00"),time_range("2010-01-12 10:30:00", "2010-01-12 11:00:00"))',[])
Expand Down

0 comments on commit 59c6e6b

Please sign in to comment.