diff --git a/test/bin/ipfs-pin-stat b/test/bin/ipfs-pin-stat index ffb0b2260..967ee9b65 100755 --- a/test/bin/ipfs-pin-stat +++ b/test/bin/ipfs-pin-stat @@ -19,12 +19,12 @@ if [ "$?" -eq 0 ]; then fi ipfs pin ls --type=recursive | grep "$path" >/dev/null -[ "$?" -eq 0 ] && echo "$path pinned recursively" +[ "$?" -eq 0 ] && echo "$path pinned recursive-ly" ipfs pin ls --type=indirect | grep "$path" >/dev/null -[ "$?" -eq 0 ] && echo "$path pinned indirectly" +[ "$?" -eq 0 ] && echo "$path pinned indirect-ly" ipfs pin ls --type=direct | grep "$path" >/dev/null -[ "$?" -eq 0 ] && echo "$path pinned directly" +[ "$?" -eq 0 ] && echo "$path pinned direct-ly" exit 0 diff --git a/test/sharness/t0081-repo-pinning.sh b/test/sharness/t0081-repo-pinning.sh index f57a86303..8b0d2bcdb 100755 --- a/test/sharness/t0081-repo-pinning.sh +++ b/test/sharness/t0081-repo-pinning.sh @@ -17,7 +17,7 @@ test_pin_flag() { echo "test_pin_flag" $@ - ipfs-pin-stat "$object" | grep "$ptype" + ipfs-pin-stat "$object" | egrep "\b$ptype\b" actual=$? if [ "$expect" = "true" ]; then