@@ -88,10 +88,11 @@ def test_write_read_with_pathlike_file(self):
88
88
self .assertEqual (d , data1 * 51 )
89
89
self .assertIsInstance (f .name , str )
90
90
91
+ # TODO: RUSTPYTHON
92
+ @unittest .expectedFailure
91
93
# The following test_write_xy methods test that write accepts
92
94
# the corresponding bytes-like object type as input
93
95
# and that the data written equals bytes(xy) in all cases.
94
- @unittest .skip ("TODO: RUSTPYTHON (memoryview.cast doesn't support shape= arg)" )
95
96
def test_write_memoryview (self ):
96
97
self .write_and_read_back (memoryview (data1 * 50 ))
97
98
m = memoryview (bytes (range (256 )))
@@ -687,7 +688,6 @@ def test_bad_params(self):
687
688
with self .assertRaises (ValueError ):
688
689
gzip .open (self .filename , "rb" , newline = "\n " )
689
690
690
- @unittest .skip ("TODO: RUSTPYTHON (io.TextIOWrapper doesn't support non-UTF8)" )
691
691
def test_encoding (self ):
692
692
# Test non-default encoding.
693
693
uncompressed = data1 .decode ("ascii" ) * 50
@@ -700,8 +700,11 @@ def test_encoding(self):
700
700
with gzip .open (self .filename , "rt" , encoding = "utf-16" ) as f :
701
701
self .assertEqual (f .read (), uncompressed )
702
702
703
+ # TODO: RUSTPYTHON
704
+ if sys .platform == "win32" :
705
+ test_encoding = unittest .expectedFailure (test_encoding )
706
+
703
707
704
- @unittest .skip ("TODO: RUSTPYTHON (io.TextIOWrapper doesn't support errors= arg)" )
705
708
def test_encoding_error_handler (self ):
706
709
# Test with non-default encoding error handler.
707
710
with gzip .open (self .filename , "wb" ) as f :
@@ -710,7 +713,8 @@ def test_encoding_error_handler(self):
710
713
as f :
711
714
self .assertEqual (f .read (), "foobar" )
712
715
713
- @unittest .skip ("TODO: RUSTPYTHON (io.TextIOWrapper doesn't respect newline=)" )
716
+ # TODO: RUSTPYTHON
717
+ @unittest .expectedFailure
714
718
def test_newline (self ):
715
719
# Test with explicit newline (universal newline mode disabled).
716
720
uncompressed = data1 .decode ("ascii" ) * 50
0 commit comments