From ed9153cb7ff160cda9bf2ec3f98d98dd9877fb5b Mon Sep 17 00:00:00 2001 From: vyzo Date: Tue, 14 Dec 2021 16:06:59 +0200 Subject: [PATCH] fix itests --- itests/kit/deals.go | 2 +- itests/kit/ensemble.go | 2 +- itests/kit/files.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/itests/kit/deals.go b/itests/kit/deals.go index 5a2121029..f8de14d62 100644 --- a/itests/kit/deals.go +++ b/itests/kit/deals.go @@ -374,7 +374,7 @@ consumeEvents: func (dh *DealHarness) ExtractFileFromCAR(ctx context.Context, file *os.File) (out *os.File) { bserv := dstest.Bserv() - ch, err := car.LoadCar(bserv.Blockstore(), file) + ch, err := car.LoadCar(ctx, bserv.Blockstore(), file) require.NoError(dh.t, err) b, err := bserv.GetBlock(ctx, ch.Roots[0]) diff --git a/itests/kit/ensemble.go b/itests/kit/ensemble.go index fa983dbdf..dfd3d8cd7 100644 --- a/itests/kit/ensemble.go +++ b/itests/kit/ensemble.go @@ -487,7 +487,7 @@ func (n *Ensemble) Start() *Ensemble { ds, err := lr.Datastore(context.TODO(), "/metadata") require.NoError(n.t, err) - err = ds.Put(datastore.NewKey("miner-address"), m.ActorAddr.Bytes()) + err = ds.Put(ctx, datastore.NewKey("miner-address"), m.ActorAddr.Bytes()) require.NoError(n.t, err) nic := storedcounter.New(ds, datastore.NewKey(modules.StorageCounterDSPrefix)) diff --git a/itests/kit/files.go b/itests/kit/files.go index 9babac941..c78352afe 100644 --- a/itests/kit/files.go +++ b/itests/kit/files.go @@ -83,7 +83,7 @@ func CreateRandomCARv1(t *testing.T, rseed, size int) (carV1FilePath string, ori require.NoError(t, car.WriteCar(ctx, dagSvc, []cid.Cid{root}, tmp)) _, err = tmp.Seek(0, io.SeekStart) require.NoError(t, err) - hd, _, err := car.ReadHeader(bufio.NewReader(tmp)) + hd, err := car.ReadHeader(bufio.NewReader(tmp)) require.NoError(t, err) require.EqualValues(t, 1, hd.Version) require.Len(t, hd.Roots, 1)