Skip to content

Commit e61ac1c

Browse files
apply review comments
1 parent 575017b commit e61ac1c

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

api/debug.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -361,7 +361,8 @@ func (d *DebugAPI) TraceCall(
361361
return tracer.GetResult()
362362
}
363363

364-
// FlowHeight returns the Flow height for the given EVM block.
364+
// FlowHeight returns the Flow height for the given EVM block specified either by EVM
365+
// block height or EVM block hash.
365366
func (d *DebugAPI) FlowHeight(
366367
_ context.Context,
367368
blockNrOrHash rpc.BlockNumberOrHash,

tests/e2e_web3js_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ func TestWeb3_E2E(t *testing.T) {
3636
runWeb3Test(t, "debug_traces_test")
3737
})
3838

39-
t.Run("test transaction traces", func(t *testing.T) {
39+
t.Run("test debug utils", func(t *testing.T) {
4040
runWeb3Test(t, "debug_util_test")
4141
})
4242

tests/web3js/debug_util_test.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
const { assert } = require('chai')
22
const helpers = require('./helpers')
3+
const conf = require('./config')
34

45
it('should retrieve flow height', async () => {
5-
response = await helpers.callRPCMethod(
6+
let response = await helpers.callRPCMethod(
67
'debug_flowHeight',
78
['latest']
89
)
910
assert.equal(response.status, 200)
1011
assert.isDefined(response.body)
1112

1213
let height = response.body.result
13-
assert.isTrue(height > 0)
14+
assert.equal(height, conf.startBlockHeight)
1415
})

0 commit comments

Comments
 (0)