*: upgrade tests to use T.Cleanup()

This commit is contained in:
Anna Shaleva 2021-03-01 14:14:15 +03:00
parent 0cec99a3ea
commit 2c81fc8b8e
41 changed files with 137 additions and 220 deletions

View file

@ -80,7 +80,6 @@ func (bc *Blockchain) getNodesByRole(t *testing.T, ok bool, r native.Role, index
func TestDesignate_DesignateAsRoleTx(t *testing.T) {
bc := newTestChain(t)
defer bc.Close()
priv, err := keys.NewPrivateKey()
require.NoError(t, err)
@ -104,7 +103,6 @@ func TestDesignate_DesignateAsRoleTx(t *testing.T) {
func TestDesignate_DesignateAsRole(t *testing.T) {
bc := newTestChain(t)
defer bc.Close()
des := bc.contracts.Designate
tx := transaction.New(netmode.UnitTestNet, []byte{}, 0)