From 4be57ee021b3d3c8caf29af85261d7edcce227fb Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Wed, 10 Jul 2019 14:12:45 -0700 Subject: env.test: fix new test for toybox echo. The test relied on the non-builtins not being toybox (or another multicall binary). A multicall binary will actually look at the symlinked name (in this case "true") and do what it says on the tin. Use a tiny shell script instead. --- tests/env.test | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/env.test b/tests/env.test index 63b9094d..00b56540 100755 --- a/tests/env.test +++ b/tests/env.test @@ -23,6 +23,8 @@ testcmd "why is this allowed" "=BLAH env | grep '^=BLAH\$'" "=BLAH\n" "" "" testcmd "replace" "A=foo PATH= `which printenv` A" "foo\n" "" "" # env bypasses shell builtins -ln -s "$(which echo)" true +echo "#!$(which sh) +echo \$@" > true +chmod a+x true testcmd "norecurse" 'env PATH="$PWD:$PATH" true hello' "hello\n" "" "" rm true -- cgit v1.2.3