Files
evm/core/main_test.go
2024-01-03 09:44:09 +01:00

23 lines
668 B
Go

// (c) 2023-2024, Lux Partners Limited. All rights reserved.
// See the file LICENSE for licensing terms.
package core
import (
"testing"
"go.uber.org/goleak"
)
// TestMain uses goleak to verify tests in this package do not leak unexpected
// goroutines.
func TestMain(m *testing.M) {
opts := []goleak.Option{
// No good way to shut down these goroutines:
goleak.IgnoreTopFunction("github.com/luxdefi/evm/core/state/snapshot.(*diskLayer).generate"),
goleak.IgnoreTopFunction("github.com/luxdefi/evm/metrics.(*meterArbiter).tick"),
goleak.IgnoreTopFunction("github.com/syndtr/goleveldb/leveldb.(*DB).mpoolDrain"),
}
goleak.VerifyTestMain(m, opts...)
}