Skip to content

Commit

Permalink
Merge pull request #230 from ava-labs/consistent-var-names
Browse files Browse the repository at this point in the history
Consistent variable names
  • Loading branch information
cam-schultz authored Jan 12, 2024
2 parents 144c3c0 + f6a7b08 commit bedf79b
Show file tree
Hide file tree
Showing 55 changed files with 479 additions and 474 deletions.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Large diffs are not rendered by default.

162 changes: 81 additions & 81 deletions abi-bindings/go/Teleporter/TeleporterMessenger/TeleporterMessenger.go

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions abi-bindings/go/Teleporter/TeleporterMessenger/event_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ func TestFilterTeleporterEvents(t *testing.T) {
},
expected: &TeleporterMessengerReceiveCrossChainMessage{
MessageID: mockMessageID,
OriginBlockchainID: mockBlockchainID,
SourceBlockchainID: mockBlockchainID,
Deliverer: deliverer,
RewardRedeemer: deliverer,
Message: message,
Expand All @@ -125,7 +125,7 @@ func TestFilterTeleporterEvents(t *testing.T) {
},
expected: &TeleporterMessengerMessageExecuted{
MessageID: mockMessageID,
OriginBlockchainID: mockBlockchainID,
SourceBlockchainID: mockBlockchainID,
},
},
}
Expand Down
6 changes: 3 additions & 3 deletions abi-bindings/go/Teleporter/TeleporterMessenger/packing.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ func init() {
var err error
teleporterMessageType, err = abi.NewType("tuple", "struct Overloader.F", []abi.ArgumentMarshaling{
{Name: "messageNonce", Type: "uint256"},
{Name: "senderAddress", Type: "address"},
{Name: "originSenderAddress", Type: "address"},
{Name: "destinationBlockchainID", Type: "bytes32"},
{Name: "destinationAddress", Type: "address"},
{Name: "requiredGasLimit", Type: "uint256"},
Expand Down Expand Up @@ -76,13 +76,13 @@ func PackSendCrossChainMessage(input TeleporterMessageInput) ([]byte, error) {
return abi.Pack("sendCrossChainMessage", input)
}

func PackRetryMessageExecution(originChainID ids.ID, message TeleporterMessage) ([]byte, error) {
func PackRetryMessageExecution(sourceBlockchainID ids.ID, message TeleporterMessage) ([]byte, error) {
abi, err := TeleporterMessengerMetaData.GetAbi()
if err != nil {
return nil, errors.Wrap(err, "failed to get abi")
}

return abi.Pack("retryMessageExecution", originChainID, message)
return abi.Pack("retryMessageExecution", sourceBlockchainID, message)
}

// PackReceiveCrossChainMessage packs a ReceiveCrossChainMessageInput to form a call to the receiveCrossChainMessage function
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
func createTestTeleporterMessage(messageNonce *big.Int) TeleporterMessage {
m := TeleporterMessage{
MessageNonce: messageNonce,
SenderAddress: common.HexToAddress("0x0123456789abcdef0123456789abcdef01234567"),
OriginSenderAddress: common.HexToAddress("0x0123456789abcdef0123456789abcdef01234567"),
DestinationBlockchainID: ids.ID{1, 2, 3, 4},
DestinationAddress: common.HexToAddress("0x0123456789abcdef0123456789abcdef01234567"),
RequiredGasLimit: big.NewInt(2),
Expand Down Expand Up @@ -109,7 +109,7 @@ func TestUnpackEvent(t *testing.T) {
},
out: new(TeleporterMessengerReceiveCrossChainMessage),
expected: &TeleporterMessengerReceiveCrossChainMessage{
OriginBlockchainID: mockBlockchainID,
SourceBlockchainID: mockBlockchainID,
MessageID: mockMessageID,
Deliverer: deliverer,
RewardRedeemer: deliverer,
Expand All @@ -125,7 +125,7 @@ func TestUnpackEvent(t *testing.T) {
out: new(TeleporterMessengerMessageExecuted),
expected: &TeleporterMessengerMessageExecuted{
MessageID: mockMessageID,
OriginBlockchainID: mockBlockchainID,
SourceBlockchainID: mockBlockchainID,
},
},
}
Expand Down
Loading

0 comments on commit bedf79b

Please sign in to comment.