@@ -935,6 +935,8 @@ def set_time(filename):
935
935
os .utime (self .fname , None )
936
936
self ._test_utime_current (set_time )
937
937
938
+ # TODO: RUSTPYTHON
939
+ @unittest .expectedFailure
938
940
def test_utime_nonexistent (self ):
939
941
now = time .time ()
940
942
filename = 'nonexistent'
@@ -1761,11 +1763,6 @@ def test_dir_fd(self):
1761
1763
def test_yields_correct_dir_fd (self ):
1762
1764
return super ().test_yields_correct_dir_fd ()
1763
1765
1764
- # TODO: RUSTPYTHON (TypeError: Can't mix strings and bytes in path components)
1765
- @unittest .expectedFailure
1766
- def test_walk_bottom_up (self ):
1767
- return super ().test_walk_bottom_up ()
1768
-
1769
1766
@unittest .skipUnless (hasattr (os , 'fwalk' ), "Test needs os.fwalk()" )
1770
1767
class BytesFwalkTests (FwalkTests ):
1771
1768
"""Tests for os.walk() with bytes."""
@@ -2450,6 +2447,8 @@ def test_fchmod(self):
2450
2447
def test_fchown (self ):
2451
2448
self .check (os .fchown , - 1 , - 1 )
2452
2449
2450
+ # TODO: RUSTPYTHON
2451
+ @unittest .expectedFailure
2453
2452
@unittest .skipUnless (hasattr (os , 'fpathconf' ), 'test needs os.fpathconf()' )
2454
2453
@unittest .skipIf (
2455
2454
support .is_emscripten or support .is_wasi ,
@@ -2514,6 +2513,11 @@ def test_blocking(self):
2514
2513
self .check (os .get_blocking )
2515
2514
self .check (os .set_blocking , True )
2516
2515
2516
+ # TODO: RUSTPYTHON
2517
+ @unittest .expectedFailure
2518
+ def test_fchdir (self ):
2519
+ return super ().test_fchdir ()
2520
+
2517
2521
2518
2522
@unittest .skipUnless (hasattr (os , 'link' ), 'requires os.link' )
2519
2523
class LinkTests (unittest .TestCase ):
@@ -2559,34 +2563,44 @@ class PosixUidGidTests(unittest.TestCase):
2559
2563
UID_OVERFLOW = (1 << 32 )
2560
2564
GID_OVERFLOW = (1 << 32 )
2561
2565
2566
+ # TODO:RUSTPYTHON
2567
+ @unittest .skip ("TODO: RUSTPYTHON; crash" )
2562
2568
@unittest .skipUnless (hasattr (os , 'setuid' ), 'test needs os.setuid()' )
2563
2569
def test_setuid (self ):
2564
2570
if os .getuid () != 0 :
2565
2571
self .assertRaises (OSError , os .setuid , 0 )
2566
2572
self .assertRaises (TypeError , os .setuid , 'not an int' )
2567
2573
self .assertRaises (OverflowError , os .setuid , self .UID_OVERFLOW )
2568
2574
2575
+ # TODO:RUSTPYTHON
2576
+ @unittest .skip ("TODO: RUSTPYTHON; crash" )
2569
2577
@unittest .skipUnless (hasattr (os , 'setgid' ), 'test needs os.setgid()' )
2570
2578
def test_setgid (self ):
2571
2579
if os .getuid () != 0 and not HAVE_WHEEL_GROUP :
2572
2580
self .assertRaises (OSError , os .setgid , 0 )
2573
2581
self .assertRaises (TypeError , os .setgid , 'not an int' )
2574
2582
self .assertRaises (OverflowError , os .setgid , self .GID_OVERFLOW )
2575
2583
2584
+ # TODO:RUSTPYTHON
2585
+ @unittest .skip ("TODO: RUSTPYTHON; crash" )
2576
2586
@unittest .skipUnless (hasattr (os , 'seteuid' ), 'test needs os.seteuid()' )
2577
2587
def test_seteuid (self ):
2578
2588
if os .getuid () != 0 :
2579
2589
self .assertRaises (OSError , os .seteuid , 0 )
2580
2590
self .assertRaises (TypeError , os .setegid , 'not an int' )
2581
2591
self .assertRaises (OverflowError , os .seteuid , self .UID_OVERFLOW )
2582
2592
2593
+ # TODO:RUSTPYTHON
2594
+ @unittest .skip ("TODO: RUSTPYTHON; crash" )
2583
2595
@unittest .skipUnless (hasattr (os , 'setegid' ), 'test needs os.setegid()' )
2584
2596
def test_setegid (self ):
2585
2597
if os .getuid () != 0 and not HAVE_WHEEL_GROUP :
2586
2598
self .assertRaises (OSError , os .setegid , 0 )
2587
2599
self .assertRaises (TypeError , os .setegid , 'not an int' )
2588
2600
self .assertRaises (OverflowError , os .setegid , self .GID_OVERFLOW )
2589
2601
2602
+ # TODO:RUSTPYTHON
2603
+ @unittest .skip ("TODO: RUSTPYTHON; crash" )
2590
2604
@unittest .skipUnless (hasattr (os , 'setreuid' ), 'test needs os.setreuid()' )
2591
2605
def test_setreuid (self ):
2592
2606
if os .getuid () != 0 :
@@ -4215,7 +4229,10 @@ def test_eventfd_select(self):
4215
4229
class TimerfdTests (unittest .TestCase ):
4216
4230
# 1 ms accuracy is reliably achievable on every platform except Android
4217
4231
# emulators, where we allow 10 ms (gh-108277).
4218
- if sys .platform == "android" and platform .android_ver ().is_emulator :
4232
+
4233
+ # XXX: RUSTPYTHON; AttributeError: module 'platform' has no attribute 'android_ver'
4234
+ #if sys.platform == "android" and platform.android_ver().is_emulator:
4235
+ if sys .platform == "android" :
4219
4236
CLOCK_RES_PLACES = 2
4220
4237
else :
4221
4238
CLOCK_RES_PLACES = 3
@@ -5420,13 +5437,17 @@ class A(os.PathLike):
5420
5437
def test_pathlike_class_getitem (self ):
5421
5438
self .assertIsInstance (os .PathLike [bytes ], types .GenericAlias )
5422
5439
5440
+ # TODO: RUSTPYTHON
5441
+ @unittest .expectedFailure
5423
5442
def test_pathlike_subclass_slots (self ):
5424
5443
class A (os .PathLike ):
5425
5444
__slots__ = ()
5426
5445
def __fspath__ (self ):
5427
5446
return ''
5428
5447
self .assertFalse (hasattr (A (), '__dict__' ))
5429
5448
5449
+ # TODO: RUSTPYTHON
5450
+ @unittest .expectedFailure
5430
5451
def test_fspath_set_to_None (self ):
5431
5452
class Foo :
5432
5453
__fspath__ = None
0 commit comments