@cryptotaxi247 / kubo / commits / 0d7ef453f

t0080: improve 'ipfs refs --unique' test

License: MIT Signed-off-by: Christian Couder <chriscool@tuxfamily.org>

Christian Couder committed Dec 5, 2015 at 08:21 UTC 0d7ef453f81f4681ace9951fba84659d1972fedb
1 file changed +3 -2
test/sharness/t0080-repo.sh
+3 -2
@@ -185,10 +185,11 @@ test_expect_success "'ipfs refs --unique' is correct" '
185 cd uniques &&
186 echo "content1" > file1 &&
187 echo "content1" > file2 &&
188 - ROOT=$(ipfs add -r -q . | tail -n1) &&
188 + ipfs add -r -q . > ../add_output &&
189 + ROOT=$(tail -n1 ../add_output) &&
190 ipfs refs --unique $ROOT >expected &&
191 ipfs add -q file1 >unique_hash &&
191 - test_cmp expected unique_hash
192 + test_cmp expected unique_hash || test_fsh cat ../add_output
193 '
194
195 test_expect_success "'ipfs refs --unique --recursive' is correct" '