mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2025-01-02 23:22:49 +00:00
config: enable Echidna for tests
Signed-off-by: Roman Khimov <roman@nspcc.ru>
This commit is contained in:
parent
dc747ce3b7
commit
ab5128fb48
5 changed files with 11 additions and 2 deletions
|
@ -22,6 +22,7 @@ ProtocolConfiguration:
|
|||
Basilisk: 6
|
||||
Cockatrice: 9
|
||||
Domovoi: 12
|
||||
Echidna: 13
|
||||
|
||||
ApplicationConfiguration:
|
||||
SkipBlockVerification: false
|
||||
|
|
|
@ -272,7 +272,7 @@ func TestBlockchain_StartFromExistingDB(t *testing.T) {
|
|||
|
||||
_, _, _, err = chain.NewMultiWithCustomConfigAndStoreNoCheck(t, customConfig, cache)
|
||||
require.Error(t, err)
|
||||
require.True(t, strings.Contains(err.Error(), fmt.Sprintf("native %s: version mismatch for the latest hardfork Domovoi (stored contract state differs from autogenerated one)", nativenames.CryptoLib)), err)
|
||||
require.True(t, strings.Contains(err.Error(), fmt.Sprintf("native %s: version mismatch for the latest hardfork Echidna (stored contract state differs from autogenerated one)", nativenames.CryptoLib)), err)
|
||||
})
|
||||
|
||||
t.Run("good", func(t *testing.T) {
|
||||
|
|
|
@ -740,6 +740,13 @@ func TestNEO_CalculateBonus(t *testing.T) {
|
|||
accH := acc.Signers[0].ScriptHash()
|
||||
rewardDistance := 10
|
||||
|
||||
// We have 11 blocks made by transactions above and we need block 13 to get Echidna.
|
||||
// Otherwise this happens:
|
||||
// logger.go:146: 2024-12-24T17:52:18.160+0300 WARN contract invocation failed {"tx": "603d1b0e29e7aaf50513689be9d5bb946c7f7fec8836f0e90897c825fb762c13", "block": 13, "error": "at instruction 120 (SYSCALL): System.Contract.CallNative failed: gas limit exceeded"}
|
||||
for range 3 {
|
||||
e.AddNewBlock(t)
|
||||
}
|
||||
|
||||
t.Run("Zero", func(t *testing.T) {
|
||||
initialGASBalance := e.Chain.GetUtilityTokenBalance(accH)
|
||||
for range rewardDistance {
|
||||
|
|
|
@ -2461,6 +2461,7 @@ func TestClient_GetVersion_Hardforks(t *testing.T) {
|
|||
config.HFBasilisk: 6,
|
||||
config.HFCockatrice: 9,
|
||||
config.HFDomovoi: 12,
|
||||
config.HFEchidna: 13,
|
||||
}
|
||||
require.InDeltaMapValues(t, expected, v.Protocol.Hardforks, 0)
|
||||
}
|
||||
|
|
|
@ -121,7 +121,7 @@ const (
|
|||
// not yet deployed to the testing basic chain.
|
||||
invokescriptContractAVM = "VwIADBQBDAMOBQYMDQIODw0DDgcJAAAAAErZMCQE2zBwaEH4J+yMqiYEEUAMFA0PAwIJAAIBAwcDBAUCAQAOBgwJStkwJATbMHFpQfgn7IyqJgQSQBNA"
|
||||
// block20StateRootLE is an LE stateroot of block #20 of basic testing chain.
|
||||
block20StateRootLE = "570ba0814003f6e6a2a2e41d1b727f8af756e9c26d2453c8316868607b66da0a"
|
||||
block20StateRootLE = "310acac4fd692ab7a90dbd7fcf6feaf1ac33aabeedf6592c4ddd08ff1dac15de"
|
||||
)
|
||||
|
||||
var (
|
||||
|
|
Loading…
Reference in a new issue