From ed1fbb695abbe6ccf4adaa4773f3623dda52a265 Mon Sep 17 00:00:00 2001 From: Eric Berquist Date: Thu, 22 Aug 2024 09:52:12 -0400 Subject: [PATCH] python3Packages.array-api-compat: refactor - use pytestFlagsArray instead of checkPhase to skip tests against cupy - remove unnecessary trivial nix-update-script for Python packages --- .../python-modules/array-api-compat/default.nix | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/pkgs/development/python-modules/array-api-compat/default.nix b/pkgs/development/python-modules/array-api-compat/default.nix index 3f25d7763b9e..6de3c073b43a 100644 --- a/pkgs/development/python-modules/array-api-compat/default.nix +++ b/pkgs/development/python-modules/array-api-compat/default.nix @@ -14,7 +14,6 @@ config, cudaSupport ? config.cudaSupport, cupy, - nix-update-script, }: buildPythonPackage rec { @@ -45,13 +44,10 @@ buildPythonPackage rec { pythonImportsCheck = [ "array_api_compat" ]; # CUDA (used via cupy) is not available in the testing sandbox - checkPhase = '' - runHook preCheck - python -m pytest -k 'not cupy' - runHook postCheck - ''; - - passthru.updateScript = nix-update-script { }; + pytestFlagsArray = [ + "-k" + "'not cupy'" + ]; meta = { homepage = "https://data-apis.org/array-api-compat";