mirror of
https://github.com/python/cpython.git
synced 2025-08-22 09:45:06 +00:00
gh-102799: remove unnecessary calls to sys.exc_info() in tests (#102800)
This commit is contained in:
parent
72186aa637
commit
b3cc11a08e
5 changed files with 124 additions and 124 deletions
|
@ -5492,10 +5492,10 @@ class TCPTimeoutTest(SocketTCPTest):
|
|||
self.fail("caught timeout instead of Alarm")
|
||||
except Alarm:
|
||||
pass
|
||||
except:
|
||||
except BaseException as e:
|
||||
self.fail("caught other exception instead of Alarm:"
|
||||
" %s(%s):\n%s" %
|
||||
(sys.exc_info()[:2] + (traceback.format_exc(),)))
|
||||
(type(e), e, traceback.format_exc()))
|
||||
else:
|
||||
self.fail("nothing caught")
|
||||
finally:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue