From 1d77a869046c119ea50837ca1f94594b64985f77 Mon Sep 17 00:00:00 2001 From: Thiago Kenji Okada Date: Tue, 10 Jan 2023 21:50:29 +0000 Subject: [PATCH] resholve: fix CLI tests --- pkgs/development/misc/resholve/default.nix | 6 +++++- pkgs/development/misc/resholve/resholve.nix | 3 ++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/pkgs/development/misc/resholve/default.nix b/pkgs/development/misc/resholve/default.nix index 4247d1ab21d7..74f45f8ed3cc 100644 --- a/pkgs/development/misc/resholve/default.nix +++ b/pkgs/development/misc/resholve/default.nix @@ -33,18 +33,22 @@ let deps = callPackage ./deps.nix { }; in rec { + # not exposed in all-packages + resholveBuildTimeOnly = removeKnownVulnerabilities resholve; # resholve itself resholve = callPackage ./resholve.nix { inherit (source) rSrc version; inherit (deps.oil) oildev; inherit (deps) configargparse; inherit resholve-utils; + # used only in tests + resholve = resholveBuildTimeOnly; }; # funcs to validate and phrase invocations of resholve # and use those invocations to build packages resholve-utils = callPackage ./resholve-utils.nix { # we can still use resholve-utils without triggering a security warn # this is safe since we will only use `resholve` at build time - resholve = removeKnownVulnerabilities resholve; + resholve = resholveBuildTimeOnly; }; } diff --git a/pkgs/development/misc/resholve/resholve.nix b/pkgs/development/misc/resholve/resholve.nix index 839d744be254..28a0e401cf5d 100644 --- a/pkgs/development/misc/resholve/resholve.nix +++ b/pkgs/development/misc/resholve/resholve.nix @@ -8,6 +8,7 @@ , oildev , configargparse , binlore +, resholve , resholve-utils }: @@ -41,7 +42,7 @@ python27.pkgs.buildPythonApplication { passthru = { inherit (resholve-utils) mkDerivation phraseSolution writeScript writeScriptBin; - tests = callPackage ./test.nix { inherit rSrc binlore python27; }; + tests = callPackage ./test.nix { inherit rSrc binlore python27 resholve; }; }; meta = with lib; {