Only test bug fix with new enough deamon

This commit is contained in:
John Ericson 2024-01-08 10:17:28 -05:00 committed by GitHub
parent eeb2f083c5
commit c4c636284e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -26,8 +26,10 @@ nix-build fixed.nix -A good2 --no-out-link
echo 'testing reallyBad...' echo 'testing reallyBad...'
nix-instantiate fixed.nix -A reallyBad && fail "should fail" nix-instantiate fixed.nix -A reallyBad && fail "should fail"
echo 'testing fixed with references...' if isDaemonNewer "2.20pre20240108"; then
expectStderr 1 nix-build fixed.nix -A badReferences | grepQuiet "not allowed to refer to other store paths" echo 'testing fixed with references...'
expectStderr 1 nix-build fixed.nix -A badReferences | grepQuiet "not allowed to refer to other store paths"
fi
# While we're at it, check attribute selection a bit more. # While we're at it, check attribute selection a bit more.
echo 'testing attribute selection...' echo 'testing attribute selection...'