aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2020-06-01 11:30:30 -0500
committerRob Landley <rob@landley.net>2020-06-01 11:39:17 -0500
commit13275d2482da48bf5c529191b091933466100752 (patch)
treebeb7c1295b30491e4231113f151b15941a179502
parent8cb4dbec6734761c0fa27aa4c3bd6e9952cb1286 (diff)
downloadtoybox-13275d2482da48bf5c529191b091933466100752.tar.gz
Fix tests.
Includes removing a test that's just gratuitously checking whether or not a corner case gratuitously differs from coreutils. (So what? Who cares?)
-rwxr-xr-xtests/file.test2
-rwxr-xr-xtests/rm.test10
2 files changed, 6 insertions, 6 deletions
diff --git a/tests/file.test b/tests/file.test
index 419da0a6..4b7b5a9e 100755
--- a/tests/file.test
+++ b/tests/file.test
@@ -17,7 +17,7 @@ BROKEN=$(readlink dangler)
testing "directory" "file ." ".: directory\n" "" ""
testing "empty" "file empty" "empty: empty\n" "" ""
-testing "bash.script" "file bash.script | grep -o ' script"' " script\n" "" ""
+testing "bash.script" "file bash.script | grep -o ' script'" " script\n" "" ""
testing "bash.script with spaces" "file bash.script2 | grep -o ' script'" " script\n" "" ""
testing "env python script" "file env.python.script" "env.python.script: python script\n" "" ""
testing "ascii" "file ascii" "ascii: ASCII text\n" "" ""
diff --git a/tests/rm.test b/tests/rm.test
index 91cd37e1..5ecbfdc1 100755
--- a/tests/rm.test
+++ b/tests/rm.test
@@ -53,10 +53,10 @@ chmod 777 one 2>/dev/null ; rm -rf one
mkdir -p d1
touch d1/f1.txt d1/f2.txt
-testing "-rv dir" \
- "rm -rv d1 | sed \"s/emoved/m/;ectory //" | sort" "rm 'd1/f1.txt'\nrm 'd1/f2.txt'\nrmdir 'd1'\n" "" ""
+testing "-rv dir" "rm -rv d1 | sed 's/emoved/m/;s/ directory/dir/' | sort" \
+ "rm 'd1/f1.txt'\nrm 'd1/f2.txt'\nrmdir 'd1'\n" "" ""
rm -rf d1
-touch "'"
-testing "-v \\'" "rm -v \\'" "rm '''\n" "" "" # TODO: coreutils escapes quote
-rm -f \'
+touch "meep"
+testing "-v" "rm -v meep | sed 's/emoved/m/'" "rm 'meep'\n" "" ""
+rm -f meep