aboutsummaryrefslogtreecommitdiff
path: root/testsuite/xxd.tests
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/xxd.tests')
-rwxr-xr-xtestsuite/xxd.tests23
1 files changed, 23 insertions, 0 deletions
diff --git a/testsuite/xxd.tests b/testsuite/xxd.tests
index 76fa96af9..2c740abc8 100755
--- a/testsuite/xxd.tests
+++ b/testsuite/xxd.tests
@@ -37,4 +37,27 @@ testing 'xxd -p -r' \
37 '' \ 37 '' \
38 '30313233343536373736353433323130 30313233343536373736353433323130' 38 '30313233343536373736353433323130 30313233343536373736353433323130'
39 39
40testing 'xxd -r skips leading whitespace and truncates at two spaces' \
41 'xxd -r' \
42 '0123456789:;<=>?@' \
43 '' "\
44 00000000: 3031 3233 3435 3637 3839 3a3b 3c3d 3e3f 0123456789:;<=>?
45 00000010: 40 @
46"
47
48testing 'xxd -p -r skips one bad char, truncates at two bad chars' \
49 'xxd -p -r' \
50 '01' \
51 '' "\
5230 !31 !!32
53"
54
55testing 'xxd -p -r ignores the nibble with 2nd char bad' \
56 'xxd -p -r' \
57 '3C6' \
58 '' "\
5933 3!4 3!!5
6036
61"
62
40exit $FAILCOUNT 63exit $FAILCOUNT