Skip to content

Commit 57edaba

Browse files
committed
Remove tests for WASI
1 parent 6fd81d4 commit 57edaba

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

Lib/test/test_posixpath.py

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -465,23 +465,15 @@ def test_realpath_invalid_paths(self):
465465
self.assertRaises(UnicodeDecodeError, realpath, path, strict=ALLOW_MISSING)
466466
else:
467467
self.assertEqual(realpath(path, strict=False), path)
468-
if support.is_wasi:
469-
self.assertRaises(OSError, realpath, path, strict=True)
470-
self.assertRaises(OSError, realpath, path, strict=ALLOW_MISSING)
471-
else:
472-
self.assertRaises(FileNotFoundError, realpath, path, strict=True)
473-
self.assertEqual(realpath(path, strict=ALLOW_MISSING), path)
468+
self.assertRaises(FileNotFoundError, realpath, path, strict=True)
469+
self.assertEqual(realpath(path, strict=ALLOW_MISSING), path)
474470
path = b'/nonexistent/\xff'
475471
if sys.platform == 'win32':
476472
self.assertRaises(UnicodeDecodeError, realpath, path, strict=False)
477473
self.assertRaises(UnicodeDecodeError, realpath, path, strict=ALLOW_MISSING)
478474
else:
479475
self.assertEqual(realpath(path, strict=False), path)
480-
if support.is_wasi:
481-
self.assertRaises(OSError, realpath, path, strict=True)
482-
self.assertRaises(OSError, realpath, path, strict=ALLOW_MISSING)
483-
else:
484-
self.assertRaises(FileNotFoundError, realpath, path, strict=True)
476+
self.assertRaises(FileNotFoundError, realpath, path, strict=True)
485477

486478
@unittest.skipUnless(hasattr(os, "symlink"),
487479
"Missing symlink implementation")

0 commit comments

Comments
 (0)