Skip to content

Commit 9a6ffaf

Browse files
committed
Include unrelated test fixes for the latest version of trio
1 parent 5063897 commit 9a6ffaf

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

tests/test_misc.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -333,9 +333,9 @@ def collect_exceptions(loop, context):
333333
)
334334
expected = [ValueError("hi"), ValueError("lo"), KeyError(), IndexError()]
335335
await raise_in_aio_loop(expected[0])
336-
with trio.testing.RaisesGroup(SystemExit, strict=False):
336+
with trio.testing.RaisesGroup(SystemExit, flatten_subgroups=True):
337337
await raise_in_aio_loop(SystemExit(0))
338-
with trio.testing.RaisesGroup(SystemExit, strict=False) as result:
338+
with trio.testing.RaisesGroup(SystemExit, flatten_subgroups=True) as result:
339339
await raise_in_aio_loop(BaseExceptionGroup("", [expected[1], SystemExit()]))
340340

341341
assert len(result.value.exceptions) == 1

tests/test_trio_asyncio.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ async def test_cancel_loop_with_tasks(autojump_clock, shield, body_raises):
124124

125125
if body_raises:
126126
catcher = trio.testing.RaisesGroup(
127-
trio.testing.Matcher(ValueError, match="hi"), strict=False
127+
trio.testing.Matcher(ValueError, match="hi"), flatten_subgroups=True,
128128
)
129129
else:
130130
catcher = contextlib.nullcontext()

0 commit comments

Comments
 (0)