mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-10-30 16:10:36 +00:00
lib/tests/strings.sh: don't pin the exact error wording
The test asserted the exact stderr of `nix-instantiate` when coercing a missing path. That wording is implementation-defined and subject to change: it differs between CppNix and Lix, and it can change between CppNix releases too. Only check that evaluation fails and that the error names the missing path.
This commit is contained in:
@@ -54,7 +54,9 @@ expectFailure() {
|
||||
fi
|
||||
}
|
||||
|
||||
expectFailure 'escapeShellArg /does-not-exist' "error: path '/does-not-exist' does not exist"
|
||||
# The exact wording is implementation-defined, so only check that the error
|
||||
# names the missing path.
|
||||
expectFailure 'escapeShellArg /does-not-exist' "error:.*/does-not-exist"
|
||||
|
||||
# Without this, there would be no need to escape the path.
|
||||
export NIX_STORE_DIR="$work/store with spaces"
|
||||
|
||||
Reference in New Issue
Block a user