doc: params/config.libevm_test.go comments and improved readability

This commit is contained in:
Arran Schlosberg 2024-08-23 15:33:02 +01:00
parent de201479a2
commit 8b42942216
No known key found for this signature in database
GPG key ID: 8A30F7E4344B4EF3

View file

@ -10,6 +10,9 @@ import (
"github.com/stretchr/testify/require"
)
// testOnlyClearRegisteredExtras SHOULD be called before every call to
// [RegisterExtras] and then defer-called afterwards. This is a workaround for
// the single-call limitation on [RegisterExtras].
func testOnlyClearRegisteredExtras() {
registeredExtras = nil
}
@ -18,10 +21,10 @@ type rawJSON struct {
json.RawMessage
}
var (
_ json.Unmarshaler = (*rawJSON)(nil)
_ json.Marshaler = (*rawJSON)(nil)
)
var _ interface {
json.Marshaler
json.Unmarshaler
} = (*rawJSON)(nil)
func TestRegisterExtras(t *testing.T) {
type (