Merge pull request #15254 from roberth/fix-test-nix-shell-in-pwd-with-plus
fix(tests): use glob instead of regex in nix-shell test
This commit is contained in:
@@ -39,8 +39,8 @@ testTmpDir=$(pwd)/nix-shell
|
||||
mkdir -p "$testTmpDir"
|
||||
# shellcheck disable=SC2016
|
||||
output=$(TMPDIR="$testTmpDir" nix-shell --pure "$shellDotNix" -A shellDrv --run 'echo $NIX_BUILD_TOP')
|
||||
[[ "$output" =~ ${testTmpDir}.* ]] || {
|
||||
echo "expected $output =~ ${testTmpDir}.*" >&2
|
||||
[[ "$output" == "${testTmpDir}"/* ]] || {
|
||||
echo "expected $output == ${testTmpDir}/*" >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user