about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--lib/get-tests.nix1
-rw-r--r--tests/default.nix7
-rw-r--r--tests/make-test.nix12
3 files changed, 14 insertions, 6 deletions
diff --git a/lib/get-tests.nix b/lib/get-tests.nix
index 2f78f58c..f14ee3cc 100644
--- a/lib/get-tests.nix
+++ b/lib/get-tests.nix
@@ -19,5 +19,6 @@ with import "${nixpkgs}/lib";
 
   vuizvui = removeAttrs (import vuizvuiTests {
     inherit system;
+    nixpkgsPath = nixpkgs;
   }) (optional excludeVuizvuiGames "games");
 }
diff --git a/tests/default.nix b/tests/default.nix
index c9cafe6c..44167e07 100644
--- a/tests/default.nix
+++ b/tests/default.nix
@@ -1,8 +1,11 @@
-{ system ? builtins.currentSystem, ... }:
+{ system ? builtins.currentSystem
+, nixpkgsPath ? import ../nixpkgs-path.nix
+, ...
+}:
 
 let
   callTest = path: import ./make-test.nix (import path) {
-    inherit system;
+    inherit system nixpkgsPath;
   };
 
 in {
diff --git a/tests/make-test.nix b/tests/make-test.nix
index d98ff87f..6015023d 100644
--- a/tests/make-test.nix
+++ b/tests/make-test.nix
@@ -1,5 +1,9 @@
-f: { system ? builtins.currentSystem, ... } @ args: let
-  nixpkgsPath = import ../nixpkgs-path.nix;
+testFun:
+
+{ system ? builtins.currentSystem
+, nixpkgsPath ? import ../nixpkgs-path.nix
+, ...
+}@args: let
 
   lib = import "${nixpkgsPath}/lib";
 
@@ -9,11 +13,11 @@ f: { system ? builtins.currentSystem, ... } @ args: let
 
   pkgs = import nixpkgsPath { inherit system; };
 
-  testArgs = if builtins.isFunction f then f (args // {
+  testArgs = if builtins.isFunction testFun then testFun (args // {
     pkgs = pkgs // {
       vuizvui = import ../pkgs { inherit pkgs; };
     };
-  }) else f;
+  }) else testFun;
 
   nodes = testArgs.nodes or (if testArgs ? machine then {
     inherit (testArgs) machine;