summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Lib/test/test_os.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_os.py b/Lib/test/test_os.py
index 0d1f60a4f3..a4cf60fed4 100644
--- a/Lib/test/test_os.py
+++ b/Lib/test/test_os.py
@@ -2112,7 +2112,7 @@ class OSErrorTests(unittest.TestCase):
for name in self.filenames:
try:
func(name, *func_args)
- except FileNotFoundError as err:
+ except OSError as err:
self.assertIs(err.filename, name)
else:
self.fail("No exception thrown by {}".format(func))