]> granicus.if.org Git - python/commitdiff
Fix a failing test introduced as part of issue #27512
authorBrett Cannon <brett@python.org>
Fri, 15 Jul 2016 18:26:53 +0000 (11:26 -0700)
committerBrett Cannon <brett@python.org>
Fri, 15 Jul 2016 18:26:53 +0000 (11:26 -0700)
Lib/test/test_os.py

index ecd2efb0e9a830c488005e23c30c3cac1f372277..6493d76c9a291cdc3962ae51239c9f9459639d06 100644 (file)
@@ -3164,9 +3164,8 @@ class TestPEP519(unittest.TestCase):
         c.__fspath__ = 1
         self.assertRaises(TypeError, self.fspath, c())
         # __fspath__ raises an exception.
-        c.__fspath__ = lambda self: self.__not_exist
         self.assertRaises(ZeroDivisionError, self.fspath,
-                          self.PathLike(ZeroDivisionError))
+                          self.PathLike(ZeroDivisionError()))
 
 # Only test if the C version is provided, otherwise TestPEP519 already tested
 # the pure Python implementation.