allowlisttest

package
v0.7.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 23, 2025 License: GPL-3.0, LGPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	TestAdminAddr   = common.HexToAddress("0x0000000000000000000000000000000000000011")
	TestEnabledAddr = common.HexToAddress("0x0000000000000000000000000000000000000022")
	TestNoRoleAddr  = common.HexToAddress("0x0000000000000000000000000000000000000033")
	TestManagerAddr = common.HexToAddress("0x0000000000000000000000000000000000000044")
)

Functions

func AllowListConfigEqualTests

func AllowListConfigEqualTests(t testing.TB, module modules.Module) map[string]precompiletest.ConfigEqualTest

func AllowListConfigVerifyTests

func AllowListConfigVerifyTests(t testing.TB, module modules.Module) map[string]precompiletest.ConfigVerifyTest

func AllowListTests

func AllowListTests(t testing.TB, module modules.Module) map[string]precompiletest.PrecompileTest

func BenchPrecompileWithAllowList

func BenchPrecompileWithAllowList(b *testing.B, module modules.Module, newStateDB func(t testing.TB) contract.StateDB, contractTests map[string]precompiletest.PrecompileTest)

func EqualPrecompileWithAllowListTests

func EqualPrecompileWithAllowListTests(t *testing.T, module modules.Module, equalTests map[string]precompiletest.ConfigEqualTest)

func RunPrecompileWithAllowListTests

func RunPrecompileWithAllowListTests(t *testing.T, module modules.Module, newStateDB func(t testing.TB) contract.StateDB, contractTests map[string]precompiletest.PrecompileTest)

func SetDefaultRoles

func SetDefaultRoles(contractAddress common.Address) func(t testing.TB, state contract.StateDB)

SetDefaultRoles returns a BeforeHook that sets roles TestAdminAddr and TestEnabledAddr to have the AdminRole and EnabledRole respectively.

func VerifyPrecompileWithAllowListTests

func VerifyPrecompileWithAllowListTests(t *testing.T, module modules.Module, verifyTests map[string]precompiletest.ConfigVerifyTest)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL