t0081: fix greping pin type
License: MIT Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Christian Couder committed
Jan 15, 2016 at 09:52 UTC
e6201151c67b3f5d1515f4c0749dabc7fffa89b3
2 files changed
+4
-4
test/bin/ipfs-pin-stat
+3
-3
@@ -19,12 +19,12 @@ if [ "$?" -eq 0 ]; then
19
fi
20
21
ipfs pin ls --type=recursive | grep "$path" >/dev/null
22
-[ "$?" -eq 0 ] && echo "$path pinned recursively"
22
+[ "$?" -eq 0 ] && echo "$path pinned recursive-ly"
23
24
ipfs pin ls --type=indirect | grep "$path" >/dev/null
25
-[ "$?" -eq 0 ] && echo "$path pinned indirectly"
25
+[ "$?" -eq 0 ] && echo "$path pinned indirect-ly"
26
27
ipfs pin ls --type=direct | grep "$path" >/dev/null
28
-[ "$?" -eq 0 ] && echo "$path pinned directly"
28
+[ "$?" -eq 0 ] && echo "$path pinned direct-ly"
29
30
exit 0
test/sharness/t0081-repo-pinning.sh
+1
-1
@@ -17,7 +17,7 @@ test_pin_flag() {
17
18
echo "test_pin_flag" $@
19
20
- ipfs-pin-stat "$object" | grep "$ptype"
20
+ ipfs-pin-stat "$object" | egrep "\b$ptype\b"
21
actual=$?
22
23
if [ "$expect" = "true" ]; then