@@ -54,6 +54,8 @@ def syntax_error_bad_indentation2(self):
54
54
def tokenizer_error_with_caret_range (self ):
55
55
compile ("blech ( " , "?" , "exec" )
56
56
57
+ # TODO: RUSTPYTHON
58
+ @unittest .expectedFailure
57
59
def test_caret (self ):
58
60
err = self .get_exception_format (self .syntax_error_with_caret ,
59
61
SyntaxError )
@@ -761,8 +763,6 @@ def e():
761
763
msg = self .get_report (e ).splitlines ()
762
764
self .assertEqual (msg [- 2 ], ' ^' )
763
765
764
- # TODO: RUSTPYTHON
765
- @unittest .expectedFailure
766
766
def test_syntax_error_no_lineno (self ):
767
767
# See #34463.
768
768
@@ -810,6 +810,8 @@ def __str__(self):
810
810
exp = f'<unknown>.{ X .__qualname__ } : I am X\n '
811
811
self .assertEqual (exp , err )
812
812
813
+ # TODO: RUSTPYTHON
814
+ @unittest .expectedFailure
813
815
def test_syntax_error_various_offsets (self ):
814
816
for offset in range (- 5 , 10 ):
815
817
for add in [0 , 2 ]:
@@ -829,6 +831,8 @@ def test_syntax_error_various_offsets(self):
829
831
exp = "\n " .join (expected )
830
832
self .assertEqual (exp , err )
831
833
834
+ # TODO: RUSTPYTHON
835
+ @unittest .expectedFailure
832
836
def test_format_exception_only_qualname (self ):
833
837
class A :
834
838
class B :
@@ -1026,8 +1030,6 @@ def inner():
1026
1030
# Local variable dict should now be empty.
1027
1031
self .assertEqual (len (inner_frame .f_locals ), 0 )
1028
1032
1029
- # TODO: RUSTPYTHON
1030
- @unittest .expectedFailure
1031
1033
def test_extract_stack (self ):
1032
1034
def extract ():
1033
1035
return traceback .extract_stack ()
@@ -1080,8 +1082,6 @@ def test_explicit_line(self):
1080
1082
f = traceback .FrameSummary ("f" , 1 , "dummy" , line = "line" )
1081
1083
self .assertEqual ("line" , f .line )
1082
1084
1083
- # TODO: RUSTPYTHON
1084
- @unittest .expectedFailure
1085
1085
def test_len (self ):
1086
1086
f = traceback .FrameSummary ("f" , 1 , "dummy" , line = "line" )
1087
1087
self .assertEqual (len (f ), 4 )
@@ -1157,17 +1157,13 @@ def test_format_smoke(self):
1157
1157
[' File "foo.py", line 1, in fred\n line\n ' ],
1158
1158
s .format ())
1159
1159
1160
- # TODO: RUSTPYTHON
1161
- @unittest .expectedFailure
1162
1160
def test_locals (self ):
1163
1161
linecache .updatecache ('/foo.py' , globals ())
1164
1162
c = test_code ('/foo.py' , 'method' )
1165
1163
f = test_frame (c , globals (), {'something' : 1 })
1166
1164
s = traceback .StackSummary .extract (iter ([(f , 6 )]), capture_locals = True )
1167
1165
self .assertEqual (s [0 ].locals , {'something' : '1' })
1168
1166
1169
- # TODO: RUSTPYTHON
1170
- @unittest .expectedFailure
1171
1167
def test_no_locals (self ):
1172
1168
linecache .updatecache ('/foo.py' , globals ())
1173
1169
c = test_code ('/foo.py' , 'method' )
@@ -1274,6 +1270,8 @@ def test_context(self):
1274
1270
self .assertEqual (exc_info [0 ], exc .exc_type )
1275
1271
self .assertEqual (str (exc_info [1 ]), str (exc ))
1276
1272
1273
+ # TODO: RUSTPYTHON
1274
+ @unittest .expectedFailure
1277
1275
def test_long_context_chain (self ):
1278
1276
def f ():
1279
1277
try :
@@ -1339,8 +1337,6 @@ def test_compact_no_cause(self):
1339
1337
self .assertEqual (exc_info [0 ], exc .exc_type )
1340
1338
self .assertEqual (str (exc_info [1 ]), str (exc ))
1341
1339
1342
- # TODO: RUSTPYTHON
1343
- @unittest .expectedFailure
1344
1340
def test_no_refs_to_exception_and_traceback_objects (self ):
1345
1341
try :
1346
1342
1 / 0
@@ -1404,8 +1400,6 @@ def raise_with_locals():
1404
1400
exc7 = traceback .TracebackException (* exc_info , limit = - 2 , capture_locals = True )
1405
1401
self .assertNotEqual (exc6 , exc7 )
1406
1402
1407
- # TODO: RUSTPYTHON
1408
- @unittest .expectedFailure
1409
1403
def test_comparison_equivalent_exceptions_are_equal (self ):
1410
1404
excs = []
1411
1405
for _ in range (2 ):
@@ -1463,8 +1457,6 @@ def test_lookup_lines(self):
1463
1457
linecache .updatecache ('/foo.py' , globals ())
1464
1458
self .assertEqual (exc .stack [0 ].line , "import sys" )
1465
1459
1466
- # TODO: RUSTPYTHON
1467
- @unittest .expectedFailure
1468
1460
def test_locals (self ):
1469
1461
linecache .updatecache ('/foo.py' , globals ())
1470
1462
e = Exception ("uh oh" )
@@ -1476,8 +1468,6 @@ def test_locals(self):
1476
1468
self .assertEqual (
1477
1469
exc .stack [0 ].locals , {'something' : '1' , 'other' : "'string'" })
1478
1470
1479
- # TODO: RUSTPYTHON
1480
- @unittest .expectedFailure
1481
1471
def test_no_locals (self ):
1482
1472
linecache .updatecache ('/foo.py' , globals ())
1483
1473
e = Exception ("uh oh" )
0 commit comments