Rob Landley | 64427a8 | 2013-03-22 00:26:12 -0500 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | |
| 3 | [ -f testing.sh ] && . testing.sh |
| 4 | |
| 5 | #testing "name" "command" "result" "infile" "stdin" |
| 6 | |
Rob Landley | 336c44a | 2016-03-02 15:20:04 -0600 | [diff] [blame] | 7 | testing "not enough args [fail]" "uuencode 2>/dev/null" "" "" "" |
Rob Landley | 64427a8 | 2013-03-22 00:26:12 -0500 | [diff] [blame] | 8 | |
Rob Landley | 336c44a | 2016-03-02 15:20:04 -0600 | [diff] [blame] | 9 | testing "uu empty file" "uuencode test" \ |
Rob Landley | a77f36d | 2013-03-28 19:28:27 -0500 | [diff] [blame] | 10 | "begin 744 test\nend\n" "" "" |
Rob Landley | 336c44a | 2016-03-02 15:20:04 -0600 | [diff] [blame] | 11 | testing "uu 1-char" "uuencode test" \ |
Rob Landley | a77f36d | 2013-03-28 19:28:27 -0500 | [diff] [blame] | 12 | "begin 744 test\n!80\`\`\nend\n" "" "a" |
Rob Landley | 336c44a | 2016-03-02 15:20:04 -0600 | [diff] [blame] | 13 | testing "uu 2-char" "uuencode test" \ |
Rob Landley | a77f36d | 2013-03-28 19:28:27 -0500 | [diff] [blame] | 14 | "begin 744 test\n\"86(\`\nend\n" "" "ab" |
Rob Landley | 336c44a | 2016-03-02 15:20:04 -0600 | [diff] [blame] | 15 | testing "uu 3-char" "uuencode test" \ |
Rob Landley | a77f36d | 2013-03-28 19:28:27 -0500 | [diff] [blame] | 16 | "begin 744 test\n#86)C\nend\n" "" "abc" |
Rob Landley | 64427a8 | 2013-03-22 00:26:12 -0500 | [diff] [blame] | 17 | |
Rob Landley | 336c44a | 2016-03-02 15:20:04 -0600 | [diff] [blame] | 18 | testing "b64 empty file" "uuencode -m test" \ |
Rob Landley | 64427a8 | 2013-03-22 00:26:12 -0500 | [diff] [blame] | 19 | "begin-base64 744 test\n====\n" "" "" |
Rob Landley | 336c44a | 2016-03-02 15:20:04 -0600 | [diff] [blame] | 20 | testing "b64 1-char" "uuencode -m test" \ |
Rob Landley | 64427a8 | 2013-03-22 00:26:12 -0500 | [diff] [blame] | 21 | "begin-base64 744 test\nYQ==\n====\n" "" "a" |
Rob Landley | 336c44a | 2016-03-02 15:20:04 -0600 | [diff] [blame] | 22 | testing "b64 2-char" "uuencode -m test" \ |
Rob Landley | 64427a8 | 2013-03-22 00:26:12 -0500 | [diff] [blame] | 23 | "begin-base64 744 test\nYWI=\n====\n" "" "ab" |
Rob Landley | 336c44a | 2016-03-02 15:20:04 -0600 | [diff] [blame] | 24 | testing "b64 3-char" "uuencode -m test" \ |
Rob Landley | 64427a8 | 2013-03-22 00:26:12 -0500 | [diff] [blame] | 25 | "begin-base64 744 test\nYWJj\n====\n" "" "abc" |
| 26 | |