mirror of
https://github.com/python/cpython.git
synced 2024-12-04 23:34:42 +08:00
The assignment to result.st_rdev can raise AttributeError as well as
TypeError (on systems where it's not defined at all, it raises AttributeError; when it's defined, assignment to it raises TypeError).
This commit is contained in:
parent
a5e616510e
commit
1fff878c45
@ -111,7 +111,7 @@ class StatAttributeTests(unittest.TestCase):
|
||||
try:
|
||||
result.st_rdev = 1
|
||||
self.fail("No exception thrown")
|
||||
except TypeError:
|
||||
except (AttributeError, TypeError):
|
||||
pass
|
||||
|
||||
try:
|
||||
|
Loading…
Reference in New Issue
Block a user