Skip to content

Commit 321094a

Browse files
committed
change wait condition in poll
wait for processes to exit, not for expected result otherwise, a timeout is forced for any incorrect result
1 parent fda489a commit 321094a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

jupyter_client/tests/test_kernelmanager.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -459,7 +459,7 @@ async def test_get_connect_info(self, async_km):
459459
)
460460
assert keys == expected
461461

462-
@pytest.mark.timeout(10)
462+
@pytest.mark.timeout(20)
463463
@pytest.mark.skipif(sys.platform == "win32", reason="Windows doesn't support signals")
464464
async def test_signal_kernel_subprocesses(self, install_kernel, start_async_kernel):
465465

@@ -499,7 +499,7 @@ async def execute(cmd):
499499
# wait up to 5s for subprocesses to handle signal
500500
for i in range(50):
501501
reply = await execute("check")
502-
if reply["user_expressions"]["poll"] != [-signal.SIGINT] * N:
502+
if any(status is None for status in reply["user_expressions"]["poll"]):
503503
await asyncio.sleep(0.1)
504504
else:
505505
break

0 commit comments

Comments
 (0)