Skip to content

Commit

Permalink
Do not treat persistent mocks as expired
Browse files Browse the repository at this point in the history
  • Loading branch information
sarayourfriend committed Mar 29, 2024
1 parent 4dd2e3a commit 9384236
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pook/mock.py
Original file line number Diff line number Diff line change
Expand Up @@ -767,7 +767,7 @@ def match(self, request):
if not matches:
return False, errors

if self.isdone():
if self._times <= 0:
return False, [f"Mock matches request but is expired.\n{repr(self)}"]

# Register matched request for further inspecion and reference
Expand Down

0 comments on commit 9384236

Please sign in to comment.