Skip to content

Commit

Permalink
use new address
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewkmin committed Jun 20, 2022
1 parent c123dfe commit 431e349
Show file tree
Hide file tree
Showing 2 changed files with 56 additions and 48 deletions.
86 changes: 47 additions & 39 deletions services/construction/construction_service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ import (
"context"
"encoding/hex"
"encoding/json"
"fmt"
"math/big"
"testing"

Expand Down Expand Up @@ -51,7 +50,15 @@ var (
toAddress = "0xefD3dc58D60aF3295B92ecd484CAEB3A2f30b3e7"
tokenContractAddress = "0x2d7882beDcbfDDce29Ba99965dd3cdF7fcB10A1e"

constructionFromAddress = "0x5aCB42b3cfCD734a57AFF800139ba1354b549159"
// key is unsafe for use in prod :)
transferAddress = constructionAddress{
privateKey: "00fe21cc72608106f87959c32c27debbbc31ad9a45e8f50021cfdf0c3d8acb1d",
compressedPublicKey: "03df5c7854e2264f641773f12fa3ce186ef1ebb294a7842ae7f3ef46ba502f7bff",
publicKey: "df5c7854e2264f641773f12fa3ce186ef1ebb294a7842ae7f3ef46ba502f7bffc990442f989d091ddaac352651de2d6f20fa0e65cc32d5283777177a41f51b7d",
address: "0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1",
}

constructionFromAddress = transferAddress.address
constructionToAddress = "0x3Fa177c2E87Cb24148EC403921dB577d140CC07c"

transferValue = uint64(20211004)
Expand All @@ -61,18 +68,18 @@ var (
transferData = "0xa9059cbb000000000000000000000000efd3dc58d60af3295b92ecd484caeb3a2f30b3e7000000000000000000000000000000000000000000000000000000000134653c" //nolint
transferGasCap = uint64(60000000000) // 60 gwei
transferGasTip = uint64(1500000000) // 1.5 gwei
transferGasCapWithTip = transferGasCap + transferGasTip
transferGasCapWithTip = transferGasCap + transferGasTip // 61.5 gwei

transferValueHex = hexutil.EncodeUint64(transferValue)
transferGasLimitHex = hexutil.EncodeUint64(transferGasLimit)
transferGasLimitERC20Hex = hexutil.EncodeUint64(transferGasLimitERC20)
transferValueHex = hexutil.EncodeUint64(transferValue) // 0x134653C
transferGasLimitHex = hexutil.EncodeUint64(transferGasLimit) // 0x5208
transferGasLimitERC20Hex = hexutil.EncodeUint64(transferGasLimitERC20) // 0xFDE8
transferNonceHex = hexutil.EncodeUint64(transferNonce)
transferNonceHex2 = "0x22"
transferGasCapHex = hexutil.EncodeUint64(transferGasCap)
transferGasTipHex = hexutil.EncodeUint64(transferGasTip)
transferGasCapWithTipHex = hexutil.EncodeUint64(transferGasCapWithTip)
transferGasCapHex = hexutil.EncodeUint64(transferGasCap) // 0xdf8475800
transferGasTipHex = hexutil.EncodeUint64(transferGasTip) // 0x59682F00
transferGasCapWithTipHex = hexutil.EncodeUint64(transferGasCapWithTip) // 0xE51AF8700

minGasCap = big.NewInt(30000000000)
minGasCap = big.NewInt(30000000000)
minGasCapHex = hexutil.EncodeUint64(minGasCap.Uint64())

header = EthTypes.Header{
Expand Down Expand Up @@ -110,6 +117,13 @@ var (
}
)

type constructionAddress struct {
privateKey string
publicKey string
compressedPublicKey string
address string
}

func forceHexDecode(t *testing.T, s string) []byte {
b, err := hex.DecodeString(s)
if err != nil {
Expand Down Expand Up @@ -144,7 +158,7 @@ func TestConstructionFlowWithPendingNonce(t *testing.T) {
publicKey := &types.PublicKey{
Bytes: forceHexDecode(
t,
"0212e9f98d9750e5f74b4b4b00df39074f86c79187943bdb3c5a9c89ffc1ed0188",
transferAddress.compressedPublicKey,
),
CurveType: types.Secp256k1,
}
Expand All @@ -155,12 +169,12 @@ func TestConstructionFlowWithPendingNonce(t *testing.T) {
assert.Nil(t, err)
assert.Equal(t, &types.ConstructionDeriveResponse{
AccountIdentifier: &types.AccountIdentifier{
Address: "0xD10a72Cf054650931365Cc44D912a4FD75257058",
Address: transferAddress.address,
},
}, deriveResponse)

// Test Preprocess
intent := `[{"operation_identifier":{"index":0},"type":"CALL","account":{"address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159"},"amount":{"value":"-1000","currency":{"symbol":"MATIC","decimals":18}}},{"operation_identifier":{"index":1},"related_operations":[{"index":0}],"type":"CALL","account":{"address":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c"},"amount":{"value":"1000","currency":{"symbol":"MATIC","decimals":18}}}]`
intent := `[{"operation_identifier":{"index":0},"type":"CALL","account":{"address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1"},"amount":{"value":"-1000","currency":{"symbol":"MATIC","decimals":18}}},{"operation_identifier":{"index":1},"related_operations":[{"index":0}],"type":"CALL","account":{"address":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c"},"amount":{"value":"1000","currency":{"symbol":"MATIC","decimals":18}}}]`
var ops []*types.Operation
assert.NoError(t, json.Unmarshal([]byte(intent), &ops))
preprocessResponse, err := servicer.ConstructionPreprocess(
Expand All @@ -171,7 +185,7 @@ func TestConstructionFlowWithPendingNonce(t *testing.T) {
},
)
assert.Nil(t, err)
optionsRaw := `{"from":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159","to":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c","value":"0x3e8"}`
optionsRaw := `{"from":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1","to":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c","value":"0x3e8"}`
var options options
assert.NoError(t, json.Unmarshal([]byte(optionsRaw), &options))
assert.Equal(t, &types.ConstructionPreprocessResponse{
Expand Down Expand Up @@ -228,27 +242,24 @@ func TestConstructionFlowWithPendingNonce(t *testing.T) {
}, metadataResponse)

// Test Payloads
unsignedRaw := `{"from":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159","to":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c","value":"0x3e8","data":"0x","nonce":"0x0","max_fee_per_gas":"0xe51af8700","max_priority_fee_per_gas":"0x59682f00","gas":"0x5208","chain_id":"0x13881"}`
unsignedRaw := `{"from":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1","to":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c","value":"0x3e8","data":"0x","nonce":"0x0","max_fee_per_gas":"0xe51af8700","max_priority_fee_per_gas":"0x59682f00","gas":"0x5208","chain_id":"0x13881"}`
payloadsResponse, err := servicer.ConstructionPayloads(ctx, &types.ConstructionPayloadsRequest{
NetworkIdentifier: networkIdentifier,
Operations: ops,
Metadata: forceMarshalMap(t, metadata),
})
assert.Nil(t, err)

payloadsRaw := `[{"address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159","hex_bytes":"0206e22e9bded068a76f89a86e0849b7e6ff8f6e8a22e1b679fd87a08635a9f2","account_identifier":{"address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159"},"signature_type":"ecdsa_recovery"}]`
payloadsRaw := `[{"address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1","hex_bytes":"0206e22e9bded068a76f89a86e0849b7e6ff8f6e8a22e1b679fd87a08635a9f2","account_identifier":{"address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1"},"signature_type":"ecdsa_recovery"}]`
var payloads []*types.SigningPayload
assert.NoError(t, json.Unmarshal([]byte(payloadsRaw), &payloads))

hexString := hexutil.Encode(payloadsResponse.Payloads[0].Bytes)
fmt.Printf("hexstring %s", hexString)
assert.Equal(t, &types.ConstructionPayloadsResponse{
UnsignedTransaction: unsignedRaw,
Payloads: payloads,
}, payloadsResponse)

// Test Parse Unsigned
parseOpsRaw := `[{"operation_identifier":{"index":0},"type":"CALL","account":{"address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159"},"amount":{"value":"-1000","currency":{"symbol":"MATIC","decimals":18}}},{"operation_identifier":{"index":1},"related_operations":[{"index":0}],"type":"CALL","account":{"address":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c"},"amount":{"value":"1000","currency":{"symbol":"MATIC","decimals":18}}}]`
parseOpsRaw := `[{"operation_identifier":{"index":0},"type":"CALL","account":{"address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1"},"amount":{"value":"-1000","currency":{"symbol":"MATIC","decimals":18}}},{"operation_identifier":{"index":1},"related_operations":[{"index":0}],"type":"CALL","account":{"address":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c"},"amount":{"value":"1000","currency":{"symbol":"MATIC","decimals":18}}}]`
var parseOps []*types.Operation
assert.NoError(t, json.Unmarshal([]byte(parseOpsRaw), &parseOps))
parseUnsignedResponse, err := servicer.ConstructionParse(ctx, &types.ConstructionParseRequest{
Expand All @@ -271,18 +282,15 @@ func TestConstructionFlowWithPendingNonce(t *testing.T) {
}, parseUnsignedResponse)

// Test Combine
signaturesRaw := `[{"hex_bytes":"9f2f61a9a90f6695b10ed04102dca3e0aa50a10263afd861761226e3e61903a62fb42a9e8d96af626e64fd20573338f41d4f90ea9834ce6aa4ff79869181699700","public_key":{"hex_bytes":"0405e82ac561143aafc13ba109677a597c8f797b07417d0addd7a346ad35882b3c4a006620e02127b9a32e90979ff93ecad0a2f577db238163a50023e393e354ff","curve_type":"secp256k1"},"signing_payload":{"hex_bytes":"0206e22e9bded068a76f89a86e0849b7e6ff8f6e8a22e1b679fd87a08635a9f2","address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159"},"signature_type":"ecdsa_recovery"}]`
signaturesRaw := `[{"hex_bytes":"660e6778daed0d34f1c976057ee9742fef962fc67ceef2fd9e291f2558b4bc4d784b2bf12f723a1741fdf76f68dd4704f795d88ac6dc2de0d60892b0391c2d4800","public_key":{"hex_bytes":"df5c7854e2264f641773f12fa3ce186ef1ebb294a7842ae7f3ef46ba502f7bffc990442f989d091ddaac352651de2d6f20fa0e65cc32d5283777177a41f51b7d","curve_type":"secp256k1"},"signing_payload":{"hex_bytes":"0206e22e9bded068a76f89a86e0849b7e6ff8f6e8a22e1b679fd87a08635a9f2","address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1"},"signature_type":"ecdsa_recovery"}]`
var signatures []*types.Signature
assert.NoError(t, json.Unmarshal([]byte(signaturesRaw), &signatures))
signedRaw := `{"type":"0x2","nonce":"0x0","gasPrice":null,"maxPriorityFeePerGas":"0x59682f00","maxFeePerGas":"0xe51af8700","gas":"0x5208","value":"0x3e8","input":"0x","v":"0x0","r":"0x9f2f61a9a90f6695b10ed04102dca3e0aa50a10263afd861761226e3e61903a6","s":"0x2fb42a9e8d96af626e64fd20573338f41d4f90ea9834ce6aa4ff798691816997","to":"0x3fa177c2e87cb24148ec403921db577d140cc07c","chainId":"0x13881","accessList":[],"hash":"0xa7c55d7deafc3a717c36162b1dad13b7738ff5898dce3c946dd879e2e73ce840"}` //nolint
signedRaw := `{"type":"0x2","nonce":"0x0","gasPrice":null,"maxPriorityFeePerGas":"0x59682f00","maxFeePerGas":"0xe51af8700","gas":"0x5208","value":"0x3e8","input":"0x","v":"0x0","r":"0x660e6778daed0d34f1c976057ee9742fef962fc67ceef2fd9e291f2558b4bc4d","s":"0x784b2bf12f723a1741fdf76f68dd4704f795d88ac6dc2de0d60892b0391c2d48","to":"0x3fa177c2e87cb24148ec403921db577d140cc07c","chainId":"0x13881","accessList":[],"hash":"0x735e09de7e8b7b660b564068cb85275edcb5a432a07148100d85d05849b3013e"}` //nolint
combineResponse, err := servicer.ConstructionCombine(ctx, &types.ConstructionCombineRequest{
NetworkIdentifier: networkIdentifier,
UnsignedTransaction: unsignedRaw,
Signatures: signatures,
})

fmt.Printf("resulting payload: %v\n", combineResponse.SignedTransaction)

assert.Nil(t, err)
assert.Equal(t, &types.ConstructionCombineResponse{
SignedTransaction: signedRaw,
Expand All @@ -308,7 +316,7 @@ func TestConstructionFlowWithPendingNonce(t *testing.T) {

// Test Hash
transactionIdentifier := &types.TransactionIdentifier{
Hash: "0xfacf81ceb293b34292ea428c64a4a550fd5702432908a952aa9d1db455c22c72",
Hash: "0x735e09de7e8b7b660b564068cb85275edcb5a432a07148100d85d05849b3013e",
}
hashResponse, err := servicer.ConstructionHash(ctx, &types.ConstructionHashRequest{
NetworkIdentifier: networkIdentifier,
Expand Down Expand Up @@ -360,7 +368,7 @@ func TestConstructionFlowWithInputNonce(t *testing.T) {
publicKey := &types.PublicKey{
Bytes: forceHexDecode(
t,
"0212e9f98d9750e5f74b4b4b00df39074f86c79187943bdb3c5a9c89ffc1ed0188",
transferAddress.compressedPublicKey,
),
CurveType: types.Secp256k1,
}
Expand All @@ -371,12 +379,12 @@ func TestConstructionFlowWithInputNonce(t *testing.T) {
assert.Nil(t, err)
assert.Equal(t, &types.ConstructionDeriveResponse{
AccountIdentifier: &types.AccountIdentifier{
Address: "0xD10a72Cf054650931365Cc44D912a4FD75257058",
Address: transferAddress.address,
},
}, deriveResponse)

// Test Preprocess
intent := `[{"operation_identifier":{"index":0},"type":"CALL","account":{"address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159"},"amount":{"value":"-1000","currency":{"symbol":"MATIC","decimals":18}}},{"operation_identifier":{"index":1},"related_operations":[{"index":0}],"type":"CALL","account":{"address":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c"},"amount":{"value":"1000","currency":{"symbol":"MATIC","decimals":18}}}]`
intent := `[{"operation_identifier":{"index":0},"type":"CALL","account":{"address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1"},"amount":{"value":"-1000","currency":{"symbol":"MATIC","decimals":18}}},{"operation_identifier":{"index":1},"related_operations":[{"index":0}],"type":"CALL","account":{"address":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c"},"amount":{"value":"1000","currency":{"symbol":"MATIC","decimals":18}}}]`
var ops []*types.Operation
assert.NoError(t, json.Unmarshal([]byte(intent), &ops))
preprocessResponse, err := servicer.ConstructionPreprocess(
Expand All @@ -388,7 +396,7 @@ func TestConstructionFlowWithInputNonce(t *testing.T) {
},
)
assert.Nil(t, err)
optionsRaw := `{"from":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159","nonce":"0x1","to":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c","value":"0x3e8"}`
optionsRaw := `{"from":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1","nonce":"0x1","to":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c","value":"0x3e8"}`
var options options
assert.NoError(t, json.Unmarshal([]byte(optionsRaw), &options))
assert.Equal(t, &types.ConstructionPreprocessResponse{
Expand All @@ -398,8 +406,8 @@ func TestConstructionFlowWithInputNonce(t *testing.T) {
// Test Metadata
metadata := &metadata{
GasLimit: 21000,
GasTip: big.NewInt(1500000000),
GasCap: big.NewInt(1501000000),
GasTip: big.NewInt(int64(transferGasTip)),
GasCap: big.NewInt(int64(transferGasCapWithTip)),
Nonce: 1,
To: constructionToAddress,
Value: big.NewInt(1000),
Expand Down Expand Up @@ -431,21 +439,21 @@ func TestConstructionFlowWithInputNonce(t *testing.T) {
Metadata: forceMarshalMap(t, metadata),
SuggestedFee: []*types.Amount{
{
Value: "31510500000000",
Value: "1291500000000000",
Currency: polygon.Currency,
},
},
}, metadataResponse)

// Test Payloads
unsignedRaw := `{"from":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159","to":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c","value":"0x3e8","data":"0x","nonce":"0x1","max_fee_per_gas":"0xe51af8700","max_priority_fee_per_gas":"0x59682f00","gas":"0x5208","chain_id":"0x13881"}`
unsignedRaw := `{"from":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1","to":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c","value":"0x3e8","data":"0x","nonce":"0x1","max_fee_per_gas":"0xe51af8700","max_priority_fee_per_gas":"0x59682f00","gas":"0x5208","chain_id":"0x13881"}`
payloadsResponse, err := servicer.ConstructionPayloads(ctx, &types.ConstructionPayloadsRequest{
NetworkIdentifier: networkIdentifier,
Operations: ops,
Metadata: forceMarshalMap(t, metadata),
})
assert.Nil(t, err)
payloadsRaw := `[{"address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159","hex_bytes":"2fbbd3c6a16a992785dbb6d6f3589d26dbc277aa83657b130b960c0da2422670","account_identifier":{"address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159"},"signature_type":"ecdsa_recovery"}]`
payloadsRaw := `[{"address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1","hex_bytes":"886c43dac9ea8064a47b2c544617c20c8d2a0e67025d59b6970887ac6cb2f81b","account_identifier":{"address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1"},"signature_type":"ecdsa_recovery"}]`
var payloads []*types.SigningPayload
assert.NoError(t, json.Unmarshal([]byte(payloadsRaw), &payloads))
assert.Equal(t, &types.ConstructionPayloadsResponse{
Expand All @@ -454,7 +462,7 @@ func TestConstructionFlowWithInputNonce(t *testing.T) {
}, payloadsResponse)

// Test Parse Unsigned
parseOpsRaw := `[{"operation_identifier":{"index":0},"type":"CALL","account":{"address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159"},"amount":{"value":"-1000","currency":{"symbol":"MATIC","decimals":18}}},{"operation_identifier":{"index":1},"related_operations":[{"index":0}],"type":"CALL","account":{"address":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c"},"amount":{"value":"1000","currency":{"symbol":"MATIC","decimals":18}}}]`
parseOpsRaw := `[{"operation_identifier":{"index":0},"type":"CALL","account":{"address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1"},"amount":{"value":"-1000","currency":{"symbol":"MATIC","decimals":18}}},{"operation_identifier":{"index":1},"related_operations":[{"index":0}],"type":"CALL","account":{"address":"0x3Fa177c2E87Cb24148EC403921dB577d140CC07c"},"amount":{"value":"1000","currency":{"symbol":"MATIC","decimals":18}}}]`
var parseOps []*types.Operation
assert.NoError(t, json.Unmarshal([]byte(parseOpsRaw), &parseOps))
parseUnsignedResponse, err := servicer.ConstructionParse(ctx, &types.ConstructionParseRequest{
Expand All @@ -477,10 +485,10 @@ func TestConstructionFlowWithInputNonce(t *testing.T) {
}, parseUnsignedResponse)

// Test Combine
signaturesRaw := `[{"hex_bytes":"188597fb9e64a6875ceb033cd55910add342dc9ea5130f8c95010cd74366dc217de32a0d4b3da60dcce83f44b43cd9e733ded9c5da53a4d08b662b8d9e1c32c100","public_key":{"hex_bytes":"0405e82ac561143aafc13ba109677a597c8f797b07417d0addd7a346ad35882b3c4a006620e02127b9a32e90979ff93ecad0a2f577db238163a50023e393e354ff","curve_type":"secp256k1"},"signing_payload":{"hex_bytes":"2fbbd3c6a16a992785dbb6d6f3589d26dbc277aa83657b130b960c0da2422670","address":"0x5aCB42b3cfCD734a57AFF800139ba1354b549159"},"signature_type":"ecdsa_recovery"}]`
signaturesRaw := `[{"hex_bytes":"e8d0fd97f5f1ce5aaa0c4c2c02d0bb1c65a1a4baa2a970efdc85e77d54f117590d953748115c85ade80806a0e4c8a9365c37b984b0837ffddda4af3397e8090000","public_key":{"hex_bytes":"0405e82ac561143aafc13ba109677a597c8f797b07417d0addd7a346ad35882b3c4a006620e02127b9a32e90979ff93ecad0a2f577db238163a50023e393e354ff","curve_type":"secp256k1"},"signing_payload":{"hex_bytes":"2fbbd3c6a16a992785dbb6d6f3589d26dbc277aa83657b130b960c0da2422670","address":"0xda75C156Bc4b518ac4b91Ee942BE2B2e2e36e8C1"},"signature_type":"ecdsa_recovery"}]`
var signatures []*types.Signature
assert.NoError(t, json.Unmarshal([]byte(signaturesRaw), &signatures))
signedRaw := `{"type":"0x2","nonce":"0x1","gasPrice":null,"maxPriorityFeePerGas":"0x59682f00","maxFeePerGas":"0xe51af8700","gas":"0x5208","value":"0x3e8","input":"0x","v":"0x0","r":"0x188597fb9e64a6875ceb033cd55910add342dc9ea5130f8c95010cd74366dc21","s":"0x7de32a0d4b3da60dcce83f44b43cd9e733ded9c5da53a4d08b662b8d9e1c32c1","to":"0x3fa177c2e87cb24148ec403921db577d140cc07c","chainId":"0x13881","accessList":[],"hash":"0x69589b9f54bfe4a25c807c9d4dac1ebf305b7e806437ebe4cc113b7847439aab"}` // nolint
signedRaw := `{"type":"0x2","nonce":"0x1","gasPrice":null,"maxPriorityFeePerGas":"0x59682f00","maxFeePerGas":"0xe51af8700","gas":"0x5208","value":"0x3e8","input":"0x","v":"0x0","r":"0xe8d0fd97f5f1ce5aaa0c4c2c02d0bb1c65a1a4baa2a970efdc85e77d54f11759","s":"0xd953748115c85ade80806a0e4c8a9365c37b984b0837ffddda4af3397e80900","to":"0x3fa177c2e87cb24148ec403921db577d140cc07c","chainId":"0x13881","accessList":[],"hash":"0x9c2c6b5e84514c1668ce5c4ae5fe169bb3662812c4042d1be5af00fb0a7168e5"}` // nolint
combineResponse, err := servicer.ConstructionCombine(ctx, &types.ConstructionCombineRequest{
NetworkIdentifier: networkIdentifier,
UnsignedTransaction: unsignedRaw,
Expand Down Expand Up @@ -510,7 +518,7 @@ func TestConstructionFlowWithInputNonce(t *testing.T) {

// Test Hash
transactionIdentifier := &types.TransactionIdentifier{
Hash: "0x69589b9f54bfe4a25c807c9d4dac1ebf305b7e806437ebe4cc113b7847439aab",
Hash: "0x9c2c6b5e84514c1668ce5c4ae5fe169bb3662812c4042d1be5af00fb0a7168e5",
}
hashResponse, err := servicer.ConstructionHash(ctx, &types.ConstructionHashRequest{
NetworkIdentifier: networkIdentifier,
Expand Down
Loading

0 comments on commit 431e349

Please sign in to comment.