summary refs log tree commit diff
path: root/pkgs/development/interpreters/python/mk-python-derivation.nix
diff options
context:
space:
mode:
authorRobert T. McGibbon <rmcgibbo@gmail.com>2021-02-19 09:58:39 -0500
committerJonathan Ringer <jonringer@users.noreply.github.com>2021-05-14 21:59:55 -0700
commit2e55b7301bdfa9a5a5e0dfa18bb99d9a2c13e12d (patch)
tree78169aacd35515b89fc5542ad4a024ae5e39da9d /pkgs/development/interpreters/python/mk-python-derivation.nix
parent7dd53fe56e52c6b0193575aca4fd5c3732a01e83 (diff)
downloadnixpkgs-2e55b7301bdfa9a5a5e0dfa18bb99d9a2c13e12d.tar
nixpkgs-2e55b7301bdfa9a5a5e0dfa18bb99d9a2c13e12d.tar.gz
nixpkgs-2e55b7301bdfa9a5a5e0dfa18bb99d9a2c13e12d.tar.bz2
nixpkgs-2e55b7301bdfa9a5a5e0dfa18bb99d9a2c13e12d.tar.lz
nixpkgs-2e55b7301bdfa9a5a5e0dfa18bb99d9a2c13e12d.tar.xz
nixpkgs-2e55b7301bdfa9a5a5e0dfa18bb99d9a2c13e12d.tar.zst
nixpkgs-2e55b7301bdfa9a5a5e0dfa18bb99d9a2c13e12d.zip
pytestCheckHook: improve disabledTestPaths whitespace handling
Diffstat (limited to 'pkgs/development/interpreters/python/mk-python-derivation.nix')
-rw-r--r--pkgs/development/interpreters/python/mk-python-derivation.nix5
1 files changed, 5 insertions, 0 deletions
diff --git a/pkgs/development/interpreters/python/mk-python-derivation.nix b/pkgs/development/interpreters/python/mk-python-derivation.nix
index e9c769821d6..4917b167046 100644
--- a/pkgs/development/interpreters/python/mk-python-derivation.nix
+++ b/pkgs/development/interpreters/python/mk-python-derivation.nix
@@ -93,6 +93,8 @@
 
 , doCheck ? config.doCheckByDefault or false
 
+, disabledTestPaths ? []
+
 , ... } @ attrs:
 
 
@@ -108,6 +110,7 @@ let
 
   self = toPythonModule (stdenv.mkDerivation ((builtins.removeAttrs attrs [
     "disabled" "checkPhase" "checkInputs" "doCheck" "doInstallCheck" "dontWrapPythonPrograms" "catchConflicts" "format"
+    "disabledTestPaths"
   ]) // {
 
     name = namePrefix + name_;
@@ -178,6 +181,8 @@ let
     # If given use the specified checkPhase, otherwise use the setup hook.
     # Longer-term we should get rid of `checkPhase` and use `installCheckPhase`.
     installCheckPhase = attrs.checkPhase;
+  } //  lib.optionalAttrs (disabledTestPaths != []) {
+      disabledTestPaths = lib.escapeShellArgs disabledTestPaths;
   }));
 
   passthru.updateScript = let