Skip to content

Commit c34844f

Browse files
committed
Rename test field cRemainingGas -> remainingGas
1 parent da2f151 commit c34844f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

libevm/legacy/legacy_test.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ func TestPrecompiledStatefulContract_Upgrade(t *testing.T) {
5050
tests := map[string]struct {
5151
envGas uint64
5252
precompileRet []byte
53-
cRemainingGas uint64
53+
remainingGas uint64
5454
cErr error
5555
wantRet []byte
5656
wantErr string
@@ -59,7 +59,7 @@ func TestPrecompiledStatefulContract_Upgrade(t *testing.T) {
5959
"call_error": {
6060
envGas: 10,
6161
precompileRet: []byte{2},
62-
cRemainingGas: 6,
62+
remainingGas: 6,
6363
cErr: errors.New("test error"),
6464
wantRet: []byte{2},
6565
wantErr: "test error",
@@ -68,7 +68,7 @@ func TestPrecompiledStatefulContract_Upgrade(t *testing.T) {
6868
"remaining_gas_exceeds_supplied_gas": {
6969
envGas: 10,
7070
precompileRet: []byte{2},
71-
cRemainingGas: 11,
71+
remainingGas: 11,
7272
wantErr: "remaining gas 11 exceeds supplied gas 10",
7373
},
7474
"zero_remaining_gas": {
@@ -80,7 +80,7 @@ func TestPrecompiledStatefulContract_Upgrade(t *testing.T) {
8080
"used_one_gas": {
8181
envGas: 10,
8282
precompileRet: []byte{2},
83-
cRemainingGas: 9,
83+
remainingGas: 9,
8484
wantRet: []byte{2},
8585
wantGasUsed: 1,
8686
},
@@ -95,7 +95,7 @@ func TestPrecompiledStatefulContract_Upgrade(t *testing.T) {
9595
gasToReturn: testCase.envGas,
9696
}
9797
c := PrecompiledStatefulContract(func(env vm.PrecompileEnvironment, input []byte, suppliedGas uint64) (ret []byte, remainingGas uint64, err error) {
98-
return testCase.precompileRet, testCase.cRemainingGas, testCase.cErr
98+
return testCase.precompileRet, testCase.remainingGas, testCase.cErr
9999
})
100100

101101
upgraded := c.Upgrade()

0 commit comments

Comments
 (0)