aboutsummaryrefslogtreecommitdiff
path: root/scripts/test/dirname.test
blob: 9afa45084dfe62255d042b8fc08b3fa0aee849c6 (plain)
1
2
3
4
5
6
7
8
9
10
#!/bin/bash

[ -f testing.sh ] && . testing.sh

#testing "name" "command" "result" "infile" "stdin"

testing "dirname /-only" "dirname ///////" "/\n" "" ""
testing "dirname trailing /" "dirname a//////" ".\n" "" ""
testing "dirname combined" "dirname /////a///b///c///d/////" "/////a///b///c\n" "" "" 
testing "dirname /a/" "dirname /////a///" "/\n" "" ""