From 9f043ce4b879664fe2ae501783a67243957bae97 Mon Sep 17 00:00:00 2001 From: Simon Willison Date: Tue, 4 Feb 2025 14:34:51 -0800 Subject: [PATCH] Three more event_loop fixtures --- tests/test_auth.py | 2 +- tests/test_black.py | 2 +- tests/test_cli.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_auth.py b/tests/test_auth.py index fd7fcc65e5..aa78a5de12 100644 --- a/tests/test_auth.py +++ b/tests/test_auth.py @@ -307,7 +307,7 @@ async def test_auth_with_dstok_token(ds_client, scenario, should_work): @pytest.mark.parametrize("expires", (None, 1000, -1000)) -def test_cli_create_token(app_client, expires): +def test_cli_create_token(event_loop, app_client, expires): secret = app_client.ds._secret runner = CliRunner(mix_stderr=False) args = ["create-token", "--secret", secret, "test"] diff --git a/tests/test_black.py b/tests/test_black.py index ccf51171b2..0448a35ea3 100644 --- a/tests/test_black.py +++ b/tests/test_black.py @@ -5,7 +5,7 @@ code_root = Path(__file__).parent.parent -def test_black(): +def test_black(event_loop): runner = CliRunner() result = runner.invoke(black.main, [str(code_root), "--check"]) assert result.exit_code == 0, result.output diff --git a/tests/test_cli.py b/tests/test_cli.py index bfb34c576f..260f317de2 100644 --- a/tests/test_cli.py +++ b/tests/test_cli.py @@ -36,7 +36,7 @@ def test_inspect_cli(app_client): assert expected_count == database["tables"][table_name]["count"] -def test_inspect_cli_writes_to_file(app_client): +def test_inspect_cli_writes_to_file(event_loop, app_client): runner = CliRunner() result = runner.invoke( cli, ["inspect", "fixtures.db", "--inspect-file", "foo.json"]