From 8eff544241ee85a27617c0146dcaaae8054e4b8d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Mur=C3=A9?= Date: Fri, 29 Nov 2019 22:21:29 +0100 Subject: [PATCH] fix some tests This commit was moved from ipfs/interface-go-ipfs-core@48dcedecd468c06e3321b4217b51f67180d07eec This commit was moved from ipfs/boxo@689e92b560ca2404db9edd1e8b65cd1a5e929881 --- core/coreiface/tests/block.go | 2 +- core/coreiface/tests/pin.go | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/core/coreiface/tests/block.go b/core/coreiface/tests/block.go index 2048dd4c2..51c099bd0 100644 --- a/core/coreiface/tests/block.go +++ b/core/coreiface/tests/block.go @@ -227,7 +227,7 @@ func (tp *TestSuite) TestBlockPin(t *testing.T) { pins, err := accPins(api.Pin().Ls(ctx)) if err != nil { - return + t.Skip(err) } if len(pins) != 1 { t.Fatal("expected 1 pin") diff --git a/core/coreiface/tests/pin.go b/core/coreiface/tests/pin.go index a968490d3..58e812084 100644 --- a/core/coreiface/tests/pin.go +++ b/core/coreiface/tests/pin.go @@ -160,7 +160,7 @@ func (tp *TestSuite) TestPinRecursive(t *testing.T) { } if list[0].Path().String() != path.IpldPath(nd3.Cid()).String() { - t.Errorf("unexpected path, %s != %s", list[0].Path().String(), path.IpfsPath(nd2.Cid()).String()) + t.Errorf("unexpected path, %s != %s", list[0].Path().String(), path.IpfsPath(nd3.Cid()).String()) } list, err = accPins(api.Pin().Ls(ctx, opt.Pin.Type.Recursive())) @@ -173,7 +173,7 @@ func (tp *TestSuite) TestPinRecursive(t *testing.T) { } if list[0].Path().String() != path.IpldPath(nd2.Cid()).String() { - t.Errorf("unexpected path, %s != %s", list[0].Path().String(), path.IpldPath(nd3.Cid()).String()) + t.Errorf("unexpected path, %s != %s", list[0].Path().String(), path.IpldPath(nd2.Cid()).String()) } list, err = accPins(api.Pin().Ls(ctx, opt.Pin.Type.Indirect())) @@ -186,7 +186,7 @@ func (tp *TestSuite) TestPinRecursive(t *testing.T) { } if list[0].Path().Cid().String() != p0.Cid().String() { - t.Error("unexpected path") + t.Errorf("unexpected path, %s != %s", list[0].Path().Cid().String(), p0.Cid().String()) } res, err := api.Pin().Verify(ctx)