diff options
Diffstat (limited to 'nixpkgs/pkgs/development/interpreters/python/tests.nix')
-rw-r--r-- | nixpkgs/pkgs/development/interpreters/python/tests.nix | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/nixpkgs/pkgs/development/interpreters/python/tests.nix b/nixpkgs/pkgs/development/interpreters/python/tests.nix index 764ab29e919b..49dfe0e4644e 100644 --- a/nixpkgs/pkgs/development/interpreters/python/tests.nix +++ b/nixpkgs/pkgs/development/interpreters/python/tests.nix @@ -20,7 +20,15 @@ let envs = let inherit python; pythonEnv = python.withPackages(ps: with ps; [ ]); - pythonVirtualEnv = python.withPackages(ps: with ps; [ virtualenv ]); + pythonVirtualEnv = if python.isPy3k + then + python.withPackages(ps: with ps; [ virtualenv ]) + else + python.buildEnv.override { + extraLibs = with python.pkgs; [ virtualenv ]; + # Collisions because of namespaces __init__.py + ignoreCollisions = true; + }; in { # Plain Python interpreter plain = rec { |