From 56cd5abfcbf371457a9a6c6fae6be81f028c4788 Mon Sep 17 00:00:00 2001 From: Antoine Pietri Date: Wed, 10 Sep 2025 10:10:24 +0200 Subject: [PATCH] python313Packages.aiohttp-client-cache: fix broken tests in 0.13.0 - The async tests need an explicit asyncio_mode=auto flag to run. - We ignore all the tests in test/integration/* to cover all the current and future tests that require an instance of the service to be running. --- .../python-modules/aiohttp-client-cache/default.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/aiohttp-client-cache/default.nix b/pkgs/development/python-modules/aiohttp-client-cache/default.nix index b4f4bfdfd8b8..2537fd7393a4 100644 --- a/pkgs/development/python-modules/aiohttp-client-cache/default.nix +++ b/pkgs/development/python-modules/aiohttp-client-cache/default.nix @@ -12,6 +12,7 @@ itsdangerous, motor, poetry-core, + pytest-asyncio, pytest-aiohttp, pytestCheckHook, redis, @@ -62,18 +63,19 @@ buildPythonPackage rec { nativeCheckInputs = [ faker + pytest-asyncio pytest-aiohttp pytestCheckHook ] ++ lib.flatten (builtins.attrValues optional-dependencies); + pytestFlags = [ "--asyncio-mode=auto" ]; + pythonImportsCheck = [ "aiohttp_client_cache" ]; disabledTestPaths = [ # Tests require running instances of the services - "test/integration/test_dynamodb.py" - "test/integration/test_redis.py" - "test/integration/test_sqlite.py" + "test/integration/*" ]; meta = with lib; {