|
|
@ -64,12 +64,11 @@ func TestState(t *testing.T) { |
|
|
|
for _, subtest := range test.Subtests() { |
|
|
|
for _, subtest := range test.Subtests() { |
|
|
|
subtest := subtest |
|
|
|
subtest := subtest |
|
|
|
key := fmt.Sprintf("%s/%d", subtest.Fork, subtest.Index) |
|
|
|
key := fmt.Sprintf("%s/%d", subtest.Fork, subtest.Index) |
|
|
|
name := name + "/" + key |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
t.Run(key+"/trie", func(t *testing.T) { |
|
|
|
t.Run(key+"/trie", func(t *testing.T) { |
|
|
|
withTrace(t, test.gasLimit(subtest), func(vmconfig vm.Config) error { |
|
|
|
withTrace(t, test.gasLimit(subtest), func(vmconfig vm.Config) error { |
|
|
|
_, _, err := test.Run(subtest, vmconfig, false) |
|
|
|
_, _, err := test.Run(subtest, vmconfig, false) |
|
|
|
return st.checkFailure(t, name+"/trie", err) |
|
|
|
return st.checkFailure(t, err) |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
t.Run(key+"/snap", func(t *testing.T) { |
|
|
|
t.Run(key+"/snap", func(t *testing.T) { |
|
|
@ -78,7 +77,7 @@ func TestState(t *testing.T) { |
|
|
|
if _, err := snaps.Journal(statedb.IntermediateRoot(false)); err != nil { |
|
|
|
if _, err := snaps.Journal(statedb.IntermediateRoot(false)); err != nil { |
|
|
|
return err |
|
|
|
return err |
|
|
|
} |
|
|
|
} |
|
|
|
return st.checkFailure(t, name+"/snap", err) |
|
|
|
return st.checkFailure(t, err) |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
@ -117,6 +116,6 @@ func withTrace(t *testing.T, gasLimit uint64, test func(vm.Config) error) { |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
t.Log("EVM operation log:\n" + buf.String()) |
|
|
|
t.Log("EVM operation log:\n" + buf.String()) |
|
|
|
} |
|
|
|
} |
|
|
|
//t.Logf("EVM output: 0x%x", tracer.Output())
|
|
|
|
// t.Logf("EVM output: 0x%x", tracer.Output())
|
|
|
|
//t.Logf("EVM error: %v", tracer.Error())
|
|
|
|
// t.Logf("EVM error: %v", tracer.Error())
|
|
|
|
} |
|
|
|
} |
|
|
|