Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.busybox.net/busybox.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite')
-rwxr-xr-xtestsuite/printf.tests10
1 files changed, 10 insertions, 0 deletions
diff --git a/testsuite/printf.tests b/testsuite/printf.tests
index 050edef71..728bbf4bf 100755
--- a/testsuite/printf.tests
+++ b/testsuite/printf.tests
@@ -143,4 +143,14 @@ testing "printf aborts on %r" \
"printf: %r: invalid format\n""1\n" \
"" ""
+testing "printf treats leading 0 as flag" \
+ "${bb}printf '%0*d\n' 2 1 2>&1; echo \$?" \
+ "01\n""0\n" \
+ "" ""
+
+testing "printf handles multiple flags" \
+ "${bb}printf '%0 d\n' 2 2>&1; echo \$?" \
+ " 2\n""0\n" \
+ "" ""
+
exit $FAILCOUNT