From ed3e0869c36e5b10417450e309cd9a4fb34ef73e Mon Sep 17 00:00:00 2001 From: Steven Allen Date: Tue, 26 Jan 2021 18:45:02 -0800 Subject: [PATCH] register tipsets with the chainstore when testing --- chain/gen/gen.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/chain/gen/gen.go b/chain/gen/gen.go index 8e749095c..0b7f6eda4 100644 --- a/chain/gen/gen.go +++ b/chain/gen/gen.go @@ -465,7 +465,12 @@ func (cg *ChainGen) NextTipSetFromMinersWithMessages(base *types.TipSet, miners } } - return store.NewFullTipSet(blks), nil + fts := store.NewFullTipSet(blks) + if err := cg.cs.PutTipSet(context.TODO(), fts.TipSet()); err != nil { + return nil, err + } + + return fts, nil } func (cg *ChainGen) makeBlock(parents *types.TipSet, m address.Address, vrfticket *types.Ticket,