From 1c58fbe4a9850f03f58afcff12823931b4db881d Mon Sep 17 00:00:00 2001 From: Sander van der Burg Date: Wed, 2 Oct 2013 12:06:02 +0200 Subject: [PATCH] Fix run-in-machine testcase + add it to the tests --- release.nix | 2 +- tests/default.nix | 6 +++++- tests/run-in-machine.nix | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/release.nix b/release.nix index 6d61b796359..ef5d9f4923d 100644 --- a/release.nix +++ b/release.nix @@ -241,7 +241,7 @@ in { let testsFor = system: mapAttrsRecursiveCond (x: !x ? test) (n: v: listToAttrs [(nameValuePair system v.test)]) - (import ./tests { inherit system; }); + (import ./tests { inherit nixpkgs system; }); in fold recursiveUpdate {} (map testsFor systems); } diff --git a/tests/default.nix b/tests/default.nix index 3fc31cf0de9..35c03a3b708 100644 --- a/tests/default.nix +++ b/tests/default.nix @@ -1,4 +1,7 @@ -{ system ? builtins.currentSystem, minimal ? false }: +{ nixpkgs ? +, system ? builtins.currentSystem +, minimal ? false +}: with import ../lib/testing.nix { inherit system minimal; }; @@ -30,4 +33,5 @@ with import ../lib/testing.nix { inherit system minimal; }; tomcat = makeTest (import ./tomcat.nix); trac = makeTest (import ./trac.nix); xfce = makeTest (import ./xfce.nix); + run-in-machine = import ./run-in-machine.nix { inherit nixpkgs system; }; } diff --git a/tests/run-in-machine.nix b/tests/run-in-machine.nix index d3c3d294b73..75bd161ec9e 100644 --- a/tests/run-in-machine.nix +++ b/tests/run-in-machine.nix @@ -5,6 +5,6 @@ with import ../lib/testing.nix { inherit system; }; runInMachine { - drv = (import nixpkgs { }).aterm; + drv = (import nixpkgs { inherit system; }).aterm; machine = { config, pkgs, ... }: { services.sshd.enable = true; }; }