From 459ac00c62728c2db61dc080c2f31090215df36a Mon Sep 17 00:00:00 2001 From: zimbatm Date: Mon, 25 Dec 2017 17:23:16 +0000 Subject: [PATCH] tests/eval-test: clean up --- tests/eval-test.sh | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/tests/eval-test.sh b/tests/eval-test.sh index 5be9103..0e7fca1 100755 --- a/tests/eval-test.sh +++ b/tests/eval-test.sh @@ -1,19 +1,15 @@ #!/bin/sh -cd $(dirname $0)/.. +set -e -find=(find . -name default.nix) +cd "$(dirname "$0")/.." -for profile in `${find[@]}`; do - echo evaluating $profile >&2 +for profile in $(find . -name default.nix); do + echo evaluating $profile >&2 - nix-build '' \ - -I nixos-config=tests/eval-test.nix \ - -I nixos-hardware-profile=$profile \ - -A system \ - --dry-run - - if [ $? -ne 0 ]; then - exit 1 - fi + nix-build '' \ + -I nixos-config=tests/eval-test.nix \ + -I nixos-hardware-profile=$profile \ + -A system \ + --dry-run done