From 657ca59c64a61b0b33a01031dc0018d3d65cb334 Mon Sep 17 00:00:00 2001 From: David Brochart Date: Fri, 15 Nov 2024 11:36:11 +0100 Subject: [PATCH] Fix tests --- pyproject.toml | 3 +++ tests/test_io.py | 8 ++------ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 5201e555..87d13e5c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -192,6 +192,9 @@ filterwarnings= [ # ignore unclosed sqlite in traits "ignore:unclosed database in .trigger_timeout' was never awaited", ] [tool.coverage.report] diff --git a/tests/test_io.py b/tests/test_io.py index 09add95f..9d14e5f2 100644 --- a/tests/test_io.py +++ b/tests/test_io.py @@ -67,7 +67,6 @@ async def test_io_isatty(iopub_thread): assert stream.isatty() -@pytest.mark.skip(reason="FIXME") async def test_io_thread(anyio_backend, iopub_thread): thread = iopub_thread thread._setup_pipe_in() @@ -80,8 +79,6 @@ async def test_io_thread(anyio_backend, iopub_thread): thread._really_send([b"hi"]) ctx1.destroy() thread.stop() - thread.close() - thread._really_send(None) async def test_background_socket(anyio_backend, iopub_thread): @@ -197,8 +194,7 @@ async def subprocess_test_echo_watch(): @pytest.mark.anyio() -# @pytest.mark.skipif(sys.platform.startswith("win"), reason="Windows") -@pytest.mark.skip(reason="FIXME") +@pytest.mark.skipif(sys.platform.startswith("win"), reason="Windows") async def test_echo_watch(ctx): """Test echo on underlying FD while capturing the same FD @@ -218,7 +214,7 @@ async def test_echo_watch(ctx): [ sys.executable, "-c", - f"import {__name__}; {__name__}.subprocess_test_echo_watch()", + f"import {__name__}, anyio; anyio.run({__name__}.subprocess_test_echo_watch)", ], env=env, capture_output=True,