Fix engine api client ambiguity in engine api sim

This commit is contained in:
jangko 2023-08-24 11:34:12 +07:00
parent 745ca026fe
commit 8773eb609d
No known key found for this signature in database
GPG Key ID: 31702AE10541E6B9
2 changed files with 14 additions and 14 deletions

View File

@ -233,8 +233,8 @@ proc fcu(cl: CLMocker, version: Version,
Result[ForkchoiceUpdatedResponse, string] =
case version
of Version.V1: cl.client.forkchoiceUpdatedV1(update, attr.V1)
of Version.V2: cl.client.forkchoiceUpdatedV2(update, attr.V2)
of Version.V3: cl.client.forkchoiceUpdatedV3(update, attr.V3)
of Version.V2: cl.client.forkchoiceUpdatedV2(update, attr)
of Version.V3: cl.client.forkchoiceUpdatedV3(update, attr)
proc getNextPayloadID*(cl: CLMocker): bool =
# Generate a random value for the PrevRandao field

View File

@ -41,19 +41,19 @@ proc forkchoiceUpdatedV1*(client: RpcClient,
wrapTrySimpleRes:
client.engine_forkchoiceUpdatedV1(update, payloadAttributes)
proc forkchoiceUpdatedV2*(client: RpcClient,
update: ForkchoiceStateV1,
payloadAttributes = none(PayloadAttributesV2)):
Result[ForkchoiceUpdatedResponse, string] =
wrapTrySimpleRes:
client.engine_forkchoiceUpdatedV2(update, payloadAttributes)
#proc forkchoiceUpdatedV2*(client: RpcClient,
# update: ForkchoiceStateV1,
# payloadAttributes = none(PayloadAttributesV2)):
# Result[ForkchoiceUpdatedResponse, string] =
# wrapTrySimpleRes:
# client.engine_forkchoiceUpdatedV2(update, payloadAttributes)
proc forkchoiceUpdatedV3*(client: RpcClient,
update: ForkchoiceStateV1,
payloadAttributes = none(PayloadAttributesV3)):
Result[ForkchoiceUpdatedResponse, string] =
wrapTrySimpleRes:
client.engine_forkchoiceUpdatedV3(update, payloadAttributes)
#proc forkchoiceUpdatedV3*(client: RpcClient,
# update: ForkchoiceStateV1,
# payloadAttributes = none(PayloadAttributesV3)):
# Result[ForkchoiceUpdatedResponse, string] =
# wrapTrySimpleRes:
# client.engine_forkchoiceUpdatedV3(update, payloadAttributes)
proc forkchoiceUpdatedV2*(client: RpcClient,
update: ForkchoiceStateV1,