File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 11#! /bin/sh
22
33cleanup () {
4+ rm tmp3/tmp2
5+ rmdir tmp3
46 rm tmp/node
57 rmdir tmp
68 rm tmp2/node
@@ -14,6 +16,8 @@ mkdir -p tmp
1416touch tmp/node
1517mkdir -p tmp2
1618touch tmp2/node
19+ mkdir -p tmp3
20+ ln -s tmp2 tmp3/
1721
1822[ " $( nvm_tree_contains_path 2>&1 ) " = " both the tree and the node path are required" ] || die ' incorrect error message with no args'
1923[ " $( nvm_tree_contains_path > /dev/null 2>&1 ; echo $? ) " = " 2" ] || die ' incorrect error code with no args'
@@ -28,4 +32,6 @@ nvm_tree_contains_path tmp2 tmp2/node || die '"tmp2" should contain "tmp2/node"'
2832
2933nvm_tree_contains_path tmp2 tmp/node && die ' "tmp2" should not contain "tmp/node"'
3034
35+ nvm_tree_contains_path tmp2 tmp3 && die ' no idea'
36+
3137cleanup
You can’t perform that action at this time.
0 commit comments