From 3f3ca2d90dba5431f9e573ec04c005c233a8887f Mon Sep 17 00:00:00 2001 From: Artturin Date: Tue, 17 Jan 2023 20:42:13 +0200 Subject: [PATCH] tests.testers.testBuildFailure.helloDoesNotFail: fix confusing output the output made me think that the test failed but did not fail testBuildFailure-helloDoesNotFail> Checking /nix/store/x6403x1llpk00i59cmr96iy92mx1f7hb-hello-2.12.1/testBuildFailure.log testBuildFailure-helloDoesNotFail> testBuildFailure: The builder did not fail, but a failure was expected! --- pkgs/build-support/testers/test/default.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/build-support/testers/test/default.nix b/pkgs/build-support/testers/test/default.nix index 26e622c8763f..0a5381b2b738 100644 --- a/pkgs/build-support/testers/test/default.nix +++ b/pkgs/build-support/testers/test/default.nix @@ -58,9 +58,10 @@ lib.recurseIntoAttrs { inherit hello; } '' echo "Checking $failed/testBuildFailure.log" - grep -F 'testBuildFailure: The builder did not fail, but a failure was expected' $failed/testBuildFailure.log + grep -F 'testBuildFailure: The builder did not fail, but a failure was expected' $failed/testBuildFailure.log >/dev/null [[ 1 = $(cat $failed/testBuildFailure.exit) ]] touch $out + echo 'All good.' ''; multiOutput = runCommand "testBuildFailure-multiOutput" {