From bf0ac164479df1bc77e4e12f93b124be13c14c07 Mon Sep 17 00:00:00 2001 From: Tyler Goodlet Date: Thu, 7 Mar 2024 21:33:07 -0500 Subject: [PATCH] Adjust `asyncio` test for stricter ctx-self-cancels Use `expect_ctx()` around the portal cancellation case, toss in a `'context'` parametrization and return just the `Context.outcome` from `main()` B) --- tests/test_infected_asyncio.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/test_infected_asyncio.py b/tests/test_infected_asyncio.py index 568708a2..78e98621 100644 --- a/tests/test_infected_asyncio.py +++ b/tests/test_infected_asyncio.py @@ -19,6 +19,8 @@ from tractor import ( from tractor.trionics import BroadcastReceiver from tractor._testing import expect_ctxc +from conftest import expect_ctxc + async def sleep_and_err( sleep_for: float = 0.1,