@cryptotaxi247 / kubo / commits / eb86f3659

Fix sharness for new not found error messages

Hector Sanjuan committed Mar 2, 2022 at 18:40 UTC eb86f3659a2b8b551220f37959dc99658e3d14eb
4 files changed +5 -5
test/sharness/t0050-block.sh
+2 -2
@@ -134,9 +134,9 @@ test_expect_success "multi-block 'ipfs block rm <invalid> <valid> <invalid>'" '
134 '
135
136 test_expect_success "multi-block 'ipfs block rm <invalid> <valid> <invalid>' output looks good" '
137 - echo "cannot remove $RANDOMHASH: blockstore: block not found" >> expect_mixed_rm &&
137 + echo "cannot remove $RANDOMHASH: ipld: $RANDOMHASH not found" >> expect_mixed_rm &&
138 echo "removed $TESTHASH" >> expect_mixed_rm &&
139 - echo "cannot remove $RANDOMHASH: blockstore: block not found" >> expect_mixed_rm &&
139 + echo "cannot remove $RANDOMHASH: ipld: $RANDOMHASH not found" >> expect_mixed_rm &&
140 echo "Error: some blocks not removed" >> expect_mixed_rm
141 test_cmp actual_mixed_rm expect_mixed_rm
142 '
test/sharness/t0054-dag-car-import-export.sh
+1 -1
@@ -179,7 +179,7 @@ test_expect_success "basic offline export of 'getting started' dag works" '
179 '
180
181
182 -echo "Error: merkledag: not found (currently offline, perhaps retry after attaching to the network)" > offline_fetch_error_expected
182 +echo "Error: block was not found locally (offline): ipld: QmYwAPJXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX not found (currently offline, perhaps retry after attaching to the network)" > offline_fetch_error_expected
183 test_expect_success "basic offline export of nonexistent cid" '
184 ! ipfs dag export QmYwAPJXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX 2> offline_fetch_error_actual >/dev/null
185 '
test/sharness/t0080-repo.sh
+1 -1
@@ -64,7 +64,7 @@ test_expect_success "'ipfs repo gc --silent' succeeds (no output)" '
64 ipfs repo gc --silent >gc_out_empty &&
65 test_cmp /dev/null gc_out_empty &&
66 test_must_fail ipfs cat "$HASH2" 2>err_expected1 &&
67 - grep "Error: merkledag: not found" err_expected1
67 + grep "Error: ipld: $HASH2 not found" err_expected1
68 '
69
70 test_kill_ipfs_daemon
test/sharness/t0081-repo-pinning.sh
+1 -1
@@ -238,7 +238,7 @@ test_expect_success "some are no longer there" '
238 test_launch_ipfs_daemon_without_network
239 test_expect_success "recursive pin fails without objects" '
240 test_must_fail ipfs pin add -r "$HASH_DIR1" 2>err_expected8 &&
241 - grep "pin: merkledag: not found" err_expected8 ||
241 + grep "Error: pin: block was not found locally (offline): ipld: $HASH_DIR1 not found" err_expected8 ||
242 test_fsh cat err_expected8
243 '
244