mirror of
https://github.com/python/cpython.git
synced 2025-07-23 11:15:24 +00:00
Issue #27040: Add loop.get_exception_handler method
This commit is contained in:
parent
7bf36dace8
commit
7ed7ce6ee7
4 changed files with 12 additions and 0 deletions
|
@ -658,8 +658,10 @@ class BaseEventLoopTests(test_utils.TestCase):
|
|||
self.loop.set_debug(True)
|
||||
self.loop._process_events = mock.Mock()
|
||||
|
||||
self.assertIsNone(self.loop.get_exception_handler())
|
||||
mock_handler = mock.Mock()
|
||||
self.loop.set_exception_handler(mock_handler)
|
||||
self.assertIs(self.loop.get_exception_handler(), mock_handler)
|
||||
handle = run_loop()
|
||||
mock_handler.assert_called_with(self.loop, {
|
||||
'exception': MOCK_ANY,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue