Skip to content

Commit a2a1cbd

Browse files
committed
native exception group
1 parent a3d638a commit a2a1cbd

File tree

6 files changed

+473
-48
lines changed

6 files changed

+473
-48
lines changed

Lib/test/test_exception_group.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@ def test_exception_is_not_generic_type(self):
1515
with self.assertRaisesRegex(TypeError, 'Exception'):
1616
Exception[OSError]
1717

18-
# TODO: RUSTPYTHON
19-
@unittest.expectedFailure
2018
def test_exception_group_is_generic_type(self):
2119
E = OSError
2220
self.assertIsInstance(ExceptionGroup[E], types.GenericAlias)
@@ -156,6 +154,7 @@ def test_ExceptionGroup(self):
156154
"ExceptionGroup('flat', "
157155
"[ValueError(1), TypeError(2)]), TypeError(2)])")
158156

157+
@unittest.expectedFailure # TODO: RUSTPYTHON
159158
def test_BaseExceptionGroup(self):
160159
eg = BaseExceptionGroup(
161160
'flat', [ValueError(1), KeyboardInterrupt(2)])
@@ -810,8 +809,6 @@ def test_split_copies_notes(self):
810809
self.assertEqual(match.__notes__, orig_notes + ["match"])
811810
self.assertEqual(rest.__notes__, orig_notes + ["rest"])
812811

813-
# TODO: RUSTPYTHON
814-
@unittest.expectedFailure
815812
def test_split_does_not_copy_non_sequence_notes(self):
816813
# __notes__ should be a sequence, which is shallow copied.
817814
# If it is not a sequence, the split parts don't get any notes.
@@ -821,8 +818,6 @@ def test_split_does_not_copy_non_sequence_notes(self):
821818
self.assertFalse(hasattr(match, '__notes__'))
822819
self.assertFalse(hasattr(rest, '__notes__'))
823820

824-
# TODO: RUSTPYTHON
825-
@unittest.expectedFailure
826821
def test_drive_invalid_return_value(self):
827822
class MyEg(ExceptionGroup):
828823
def derive(self, excs):

0 commit comments

Comments
 (0)