blockchain: server runs goroutine instead of blockchain init

rework initBlockChain in order to have controllable way of running
blockchain;
remove context from initBlockChain func;
This commit is contained in:
Vsevolod Brekelov 2019-09-17 15:27:40 +03:00
parent 39a024eb03
commit adc880d323
4 changed files with 9 additions and 9 deletions

View file

@ -153,7 +153,7 @@ func newTestChain(t *testing.T) *Blockchain {
if err != nil {
t.Fatal(err)
}
chain, err := NewBlockchain(context.Background(), storage.NewMemoryStore(), cfg.ProtocolConfiguration)
chain, err := NewBlockchain(storage.NewMemoryStore(), cfg.ProtocolConfiguration)
if err != nil {
t.Fatal(err)
}