Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(minor-ampd): update sui module emitting events #643

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 3 additions & 7 deletions ampd/src/sui/verifier.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,7 @@ impl EventType {
EventType::ContractCall => "ContractCall",
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merge this PR in coordination with other repos, so e2e tests don't break

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we don't have e2e test for this

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Joao added Sui -> Amplifier last week

EventType::SignersRotated => "SignersRotated",
};

let module = match self {
EventType::ContractCall => "gateway",
EventType::SignersRotated => "auth",
};
let module = "events";

format!("{}::{}::{}", gateway_address, module, event)
.parse()
Expand Down Expand Up @@ -376,7 +372,7 @@ mod tests {
sender: msg.source_address,
type_: StructTag {
address: gateway_address.into(),
module: "gateway".parse().unwrap(),
module: "events".parse().unwrap(),
name: "ContractCall".parse().unwrap(),
type_params: vec![],
},
Expand Down Expand Up @@ -463,7 +459,7 @@ mod tests {
sender: SuiAddress::random_for_testing_only(),
type_: StructTag {
address: gateway_address.into(),
module: "auth".parse().unwrap(),
module: "events".parse().unwrap(),
name: "SignersRotated".parse().unwrap(),
type_params: vec![],
},
Expand Down
Loading