|
1 | 1 | package suite_engine
|
2 | 2 |
|
3 | 3 | import (
|
4 |
| - api "github.com/ethereum/go-ethereum/beacon/engine" |
5 | 4 | "github.com/ethereum/hive/simulators/ethereum/engine/clmock"
|
6 | 5 | "github.com/ethereum/hive/simulators/ethereum/engine/config"
|
7 | 6 | "github.com/ethereum/hive/simulators/ethereum/engine/helper"
|
@@ -74,58 +73,3 @@ func (tc ForkchoiceUpdatedOnPayloadRequestTest) Execute(t *test.Env) {
|
74 | 73 | },
|
75 | 74 | })
|
76 | 75 | }
|
77 |
| - |
78 |
| -// Test modifying the ForkchoiceUpdated version on HeadBlockHash update to the previous/upcoming |
79 |
| -// version when the timestamp payload attribute does not match the upgraded/downgraded version. |
80 |
| -type ForkchoiceUpdatedOnHeadBlockUpdateTest struct { |
81 |
| - test.BaseSpec |
82 |
| - helper.ForkchoiceUpdatedCustomizer |
83 |
| -} |
84 |
| - |
85 |
| -func (s ForkchoiceUpdatedOnHeadBlockUpdateTest) WithMainFork(fork config.Fork) test.Spec { |
86 |
| - specCopy := s |
87 |
| - specCopy.MainFork = fork |
88 |
| - return specCopy |
89 |
| -} |
90 |
| - |
91 |
| -func (tc ForkchoiceUpdatedOnHeadBlockUpdateTest) GetName() string { |
92 |
| - return "ForkchoiceUpdated Version on Head Set: " + tc.BaseSpec.GetName() |
93 |
| -} |
94 |
| - |
95 |
| -func (tc ForkchoiceUpdatedOnHeadBlockUpdateTest) Execute(t *test.Env) { |
96 |
| - // Wait until TTD is reached by this client |
97 |
| - t.CLMock.WaitForTTD() |
98 |
| - |
99 |
| - t.CLMock.ProduceSingleBlock(clmock.BlockProcessCallbacks{ |
100 |
| - OnPayloadAttributesGenerated: func() { |
101 |
| - var ( |
102 |
| - forkchoiceState *api.ForkchoiceStateV1 = &api.ForkchoiceStateV1{ |
103 |
| - HeadBlockHash: t.CLMock.LatestPayloadBuilt.BlockHash, |
104 |
| - SafeBlockHash: t.CLMock.LatestForkchoice.SafeBlockHash, |
105 |
| - FinalizedBlockHash: t.CLMock.LatestForkchoice.FinalizedBlockHash, |
106 |
| - } |
107 |
| - expectedError *int |
108 |
| - expectedStatus test.PayloadStatus = test.Valid |
109 |
| - err error |
110 |
| - ) |
111 |
| - tc.SetEngineAPIVersionResolver(t.ForkConfig) |
112 |
| - testEngine := t.TestEngine.WithEngineAPIVersionResolver(tc.ForkchoiceUpdatedCustomizer) |
113 |
| - expectedError, err = tc.GetExpectedError() |
114 |
| - if err != nil { |
115 |
| - t.Fatalf("FAIL: Error getting custom expected error: %v", err) |
116 |
| - } |
117 |
| - if tc.GetExpectInvalidStatus() { |
118 |
| - expectedStatus = test.Invalid |
119 |
| - } |
120 |
| - |
121 |
| - r := testEngine.TestEngineForkchoiceUpdated(forkchoiceState, nil, t.CLMock.LatestPayloadBuilt.Timestamp) |
122 |
| - r.ExpectationDescription = tc.Expectation |
123 |
| - if expectedError != nil { |
124 |
| - r.ExpectErrorCode(*expectedError) |
125 |
| - } else { |
126 |
| - r.ExpectNoError() |
127 |
| - r.ExpectPayloadStatus(expectedStatus) |
128 |
| - } |
129 |
| - }, |
130 |
| - }) |
131 |
| -} |
0 commit comments