Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
brentstone committed Sep 4, 2024
1 parent bbb14f9 commit b8ca528
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 12 deletions.
14 changes: 7 additions & 7 deletions crates/governance/src/vp/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2187,7 +2187,7 @@ mod test {
}

#[test]
fn test_goverance_vote_validator_success() {
fn test_governance_vote_validator_success() {
let mut state = init_storage();

let proposal_id = 0;
Expand Down Expand Up @@ -2268,7 +2268,7 @@ mod test {

let height = state.in_mem().get_block_height().0 + (7 * 2);

update_epoch_to(&mut state, 7, height);
update_epoch_to(&mut state, 6, height);

let validator_address = established_address_1();

Expand Down Expand Up @@ -2316,7 +2316,7 @@ mod test {
}

#[test]
fn test_goverance_vote_validator_out_of_voting_window_fail() {
fn test_governance_vote_validator_out_of_voting_window_fail() {
let mut state = init_storage();

let proposal_id = 0;
Expand Down Expand Up @@ -2445,7 +2445,7 @@ mod test {
}

#[test]
fn test_goverance_vote_validator_fail() {
fn test_governance_vote_validator_fail() {
let mut state = init_storage();

let proposal_id = 0;
Expand Down Expand Up @@ -2574,7 +2574,7 @@ mod test {
}

#[test]
fn test_goverance_vote_delegator_success() {
fn test_governance_vote_delegator_success() {
let mut state = init_storage();

let proposal_id = 0;
Expand Down Expand Up @@ -2720,7 +2720,7 @@ mod test {
}

#[test]
fn test_goverance_vote_delegator_fail() {
fn test_governance_vote_delegator_fail() {
let mut state = init_storage();

let proposal_id = 0;
Expand Down Expand Up @@ -2866,7 +2866,7 @@ mod test {
}

#[test]
fn test_goverance_vote_invalid_verifier_fail() {
fn test_governance_vote_invalid_verifier_fail() {
let mut state = init_storage();

let proposal_id = 0;
Expand Down
5 changes: 2 additions & 3 deletions crates/tests/src/e2e/ledger_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2134,10 +2134,9 @@ fn proposal_change_shielded_reward() -> Result<()> {
let mut client = run!(test, Bin::Client, query_proposal, Some(15))?;
client.exp_string("Proposal Id: 0")?;
client.exp_string(
"passed with 100000.000000 yay votes, 900.000000 nay votes and \
"Passed with 100000.000000 yay votes, 900.000000 nay votes and \
0.000000 abstain votes, total voting power: 100900.000000, threshold \
(fraction) of total voting power needed to tally: 67266.666667 \
(0.666666666669)",
(fraction) of total voting power needed to tally: 40360.000000 (0.4)",
)?;
client.assert_success();

Expand Down
3 changes: 1 addition & 2 deletions crates/tests/src/integration/ledger_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -856,8 +856,7 @@ fn proposal_submission() -> Result<()> {
let expected = regex::escape(
"Passed with 120000.000000 yay votes, 900.000000 nay votes and \
0.000000 abstain votes, total voting power: 120900.000000, threshold \
(fraction) of total voting power needed to tally: 80600.000000 \
(0.666666666666)",
(fraction) of total voting power needed to tally: 48360.000000 (0.4)",
);
assert!(captured.contains(&expected));

Expand Down

0 comments on commit b8ca528

Please sign in to comment.