@@ -213,17 +213,26 @@ class MyEG(ExceptionGroup):
213213 eg = BaseExceptionGroup ('test' , excs )
214214
215215 # Ensure that immutable sequences still work fine.
216- self .assertEqual (repr (eg ), "BaseExceptionGroup('test', (ValueError(1), KeyboardInterrupt(2)))" )
216+ self .assertEqual (
217+ repr (eg ),
218+ "BaseExceptionGroup('test', (ValueError(1), KeyboardInterrupt(2)))"
219+ )
217220
218221 # Test non-standard custom sequences.
219222 excs = collections .deque ([ValueError (1 ), TypeError (2 )])
220223 eg = ExceptionGroup ('test' , excs )
221224
222- self .assertEqual (repr (eg ), "ExceptionGroup('test', deque([ValueError(1), TypeError(2)]))" )
225+ self .assertEqual (
226+ repr (eg ),
227+ "ExceptionGroup('test', deque([ValueError(1), TypeError(2)]))"
228+ )
223229 excs .clear ()
224230
225231 # Ensure that clearing the exceptions sequence doesn't change the repr.
226- self .assertEqual (repr (eg ), "ExceptionGroup('test', deque([ValueError(1), TypeError(2)]))" )
232+ self .assertEqual (
233+ repr (eg ),
234+ "ExceptionGroup('test', deque([ValueError(1), TypeError(2)]))"
235+ )
227236
228237 def test_repr_raises (self ):
229238 class MySeq (collections .abc .Sequence ):
@@ -243,7 +252,10 @@ def __repr__(self):
243252 raise self .raises
244253 return None
245254
246- with self .assertRaisesRegex (TypeError , r".*MySeq\.__repr__\(\) must return a str, not NoneType" ):
255+ with self .assertRaisesRegex (
256+ TypeError ,
257+ r".*MySeq\.__repr__\(\) must return a str, not NoneType"
258+ ):
247259 ExceptionGroup ("test" , MySeq (None ))
248260
249261 with self .assertRaises (ValueError ):
0 commit comments