Add check for replacement call count at the end of the test as well.

pull/3034/head
derekpierre 2022-12-09 09:38:18 -05:00
parent 89757c6e3a
commit 76fe19487a
1 changed files with 2 additions and 0 deletions

View File

@ -342,6 +342,7 @@ def test_work_tracker(
# initial call + 5 replacements until is_operator_confirmed is mocked to True
# (no more afterwards)
assert confirmation_spy.call_count == 6
assert replacement_confirmation_spy.call_count == 5
# now that operator is confirmed there should be no more confirm_operator calls
for i in range(3):
@ -349,3 +350,4 @@ def test_work_tracker(
yield d
assert confirmation_spy.call_count == 6 # no change in number
assert replacement_confirmation_spy.call_count == 5