python/hooks: fix test attribute eval

Without the change `tests` attribute fails the eval as:

    $ nix build --no-link -f. pypy27Packages.pypaBuildHook.tests
    error:
           69|       #   versions of this hook's dependencies.
           70|       passthru.tests = import ./pypa-build-hook-tests.nix {
             |                        ^

Fixed file name and added missing runCommand import.
This commit is contained in:
Sergei Trofimovich 2023-12-29 11:27:59 +00:00
parent d20560a3ad
commit 089b731d87

View File

@ -2,6 +2,7 @@ self: dontUse: with self;
let
inherit (python) pythonOnBuildForHost;
inherit (pkgs) runCommand;
pythonInterpreter = pythonOnBuildForHost.interpreter;
pythonSitePackages = python.sitePackages;
pythonCheckInterpreter = python.interpreter;
@ -67,7 +68,7 @@ in {
# Such conflicts don't happen within the standard nixpkgs python package
# set, but in downstream projects that build packages depending on other
# versions of this hook's dependencies.
passthru.tests = import ./pypa-build-hook-tests.nix {
passthru.tests = import ./pypa-build-hook-test.nix {
inherit pythonOnBuildForHost runCommand;
};
} ./pypa-build-hook.sh) {