Skip to content

Commit

Permalink
Fix ITF structs
Browse files Browse the repository at this point in the history
  • Loading branch information
romac committed Nov 30, 2023
1 parent c560a17 commit f32fe68
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions Code/itf/src/votekeeper.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ pub struct RoundVotes {
pub round: Round,
pub prevotes: VoteCount,
pub precommits: VoteCount,
pub emitted_events: HashSet<ExecutorEvent>,
pub emitted_outputs: HashSet<VoteKeeperOutput>,
#[serde(with = "As::<HashMap<Same, Integer>>")]
pub votes_addresses_weights: HashMap<Address, Weight>,
}
Expand All @@ -57,7 +57,7 @@ pub struct VoteCount {
}

#[derive(Clone, Debug, PartialEq, Eq, Deserialize, Hash)]
pub struct ExecutorEvent {
pub struct VoteKeeperOutput {
#[serde(with = "As::<Integer>")]
pub round: Round,
pub name: String,
Expand All @@ -69,7 +69,7 @@ pub struct State {
#[serde(rename = "voteBookkeeperTest::voteBookkeeperSM::bookkeeper")]
pub bookkeeper: Bookkeeper,
#[serde(rename = "voteBookkeeperTest::voteBookkeeperSM::lastEmitted")]
pub last_emitted: ExecutorEvent,
pub last_emitted: VoteKeeperOutput,
#[serde(rename = "voteBookkeeperTest::voteBookkeeperSM::weightedVote")]
#[serde(with = "As::<(Same, Integer, Integer)>")]
pub weighted_vote: (Vote, Weight, Round),
Expand Down
2 changes: 1 addition & 1 deletion Code/itf/tests/votekeeper/runner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ impl ItfRunner for VoteKeeperRunner {

let actual_round = actual_state.per_round().get(&Round::new(round)).unwrap();

let expected_events = &expected_round.emitted_events;
let expected_events = &expected_round.emitted_outputs;
let actual_events = actual_round.emitted_msgs();

assert_eq!(
Expand Down

0 comments on commit f32fe68

Please sign in to comment.