]> granicus.if.org Git - python/commitdiff
#3580: fix a failure in test_os
authorAntoine Pitrou <solipsis@pitrou.net>
Sun, 17 Aug 2008 20:15:07 +0000 (20:15 +0000)
committerAntoine Pitrou <solipsis@pitrou.net>
Sun, 17 Aug 2008 20:15:07 +0000 (20:15 +0000)
Lib/test/test_os.py

index 7cfae4498eec3dbce33eda7b4b517e8231c8b3eb..b644bdcdcd93ec74cceb36a68388799bc13a4904 100644 (file)
@@ -313,7 +313,7 @@ class StatAttributeTests(unittest.TestCase):
             try:
                 os.stat(r"c:\pagefile.sys")
             except WindowsError, e:
-                if e == 2: # file does not exist; cannot run test
+                if e.errno == 2: # file does not exist; cannot run test
                     return
                 self.fail("Could not stat pagefile.sys")