From 23f111d1dcc051a8911656cb7311dcd99328a7ad Mon Sep 17 00:00:00 2001 From: Jakub Matys Date: Wed, 3 Oct 2018 11:35:48 +0200 Subject: [PATCH] Resets params registry when each test is done --- tests/integration.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/integration.go b/tests/integration.go index f057a5f3..990a6064 100644 --- a/tests/integration.go +++ b/tests/integration.go @@ -15,6 +15,8 @@ import ( "path/filepath" "reflect" "testing" + + "github.com/jakm/btcutil/chaincfg" ) type TestFunc func(t *testing.T, coin string, chain bchain.BlockChain, testConfig json.RawMessage) @@ -52,6 +54,7 @@ func runTests(t *testing.T, coin string, cfg map[string]json.RawMessage) { if cfg == nil || len(cfg) == 0 { t.Skip("No tests to run") } + defer chaincfg.ResetParams() bc, err := makeBlockChain(coin) if err != nil {