Skip to content

Commit

Permalink
using assert_called_once()
Browse files Browse the repository at this point in the history
  • Loading branch information
auvipy committed Oct 18, 2023
1 parent 67af9dc commit 4c9edc1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion t/unit/asynchronous/test_hub.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ def test_call_soon_uses_lock(self):
callback = Mock(name='callback')
with patch.object(self.hub, '_ready_lock', autospec=True) as lock:
self.hub.call_soon(callback)
assert lock.__enter__.called_once()
lock.__enter__.assert_called_once()

def test_call_soon__promise_argument(self):
callback = promise(Mock(name='callback'), (1, 2, 3))
Expand Down

0 comments on commit 4c9edc1

Please sign in to comment.