test: fix mishandling of "test '(' = '('" and similar
function old new delta
test_main 246 350 +104
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
diff --git a/testsuite/test.tests b/testsuite/test.tests
index 2c92e34..1c2edaf 100755
--- a/testsuite/test.tests
+++ b/testsuite/test.tests
@@ -76,4 +76,24 @@
"0\n" \
"" ""
+testing "test '!' = '!': should be true (0)" \
+ "busybox test '!' = '!'; echo \$?" \
+ "0\n" \
+ "" ""
+
+testing "test '(' = '(': should be true (0)" \
+ "busybox test '(' = '('; echo \$?" \
+ "0\n" \
+ "" ""
+
+testing "test '!' '!' = '!': should be false (1)" \
+ "busybox test '!' '!' = '!'; echo \$?" \
+ "1\n" \
+ "" ""
+
+testing "test '!' '(' = '(': should be false (1)" \
+ "busybox test '!' '(' = '('; echo \$?" \
+ "1\n" \
+ "" ""
+
exit $FAILCOUNT