Run cargo fmt on the whole code base (#9394)

* Run cargo fmt on the whole code base

* Second run

* Add CI check

* Fix compilation

* More unnecessary braces

* Handle weights

* Use --all

* Use correct attributes...

* Fix UI tests

* AHHHHHHHHH

* 🤦

* Docs

* Fix compilation

* 🤷

* Please stop

* 🤦 x 2

* More

* make rustfmt.toml consistent with polkadot

Co-authored-by: André Silva <andrerfosilva@gmail.com>
This commit is contained in:
Bastian Köcher
2021-07-21 16:32:32 +02:00
committed by GitHub
parent d451c38c1c
commit 7b56ab15b4
1010 changed files with 53339 additions and 51208 deletions
@@ -23,7 +23,10 @@ use super::*;
fn overvoting_should_fail() {
new_test_ext().execute_with(|| {
let r = begin_referendum();
assert_noop!(Democracy::vote(Origin::signed(1), r, aye(2)), Error::<Test>::InsufficientFunds);
assert_noop!(
Democracy::vote(Origin::signed(1), r, aye(2)),
Error::<Test>::InsufficientFunds
);
});
}
@@ -102,7 +105,7 @@ fn controversial_voting_should_work() {
2,
set_balance_proposal_hash_and_note(2),
VoteThreshold::SuperMajorityApprove,
0
0,
);
assert_ok!(Democracy::vote(Origin::signed(1), r, big_aye(1)));
@@ -128,7 +131,7 @@ fn controversial_low_turnout_voting_should_work() {
2,
set_balance_proposal_hash_and_note(2),
VoteThreshold::SuperMajorityApprove,
0
0,
);
assert_ok!(Democracy::vote(Origin::signed(5), r, big_nay(5)));
assert_ok!(Democracy::vote(Origin::signed(6), r, big_aye(6)));
@@ -152,7 +155,7 @@ fn passing_low_turnout_voting_should_work() {
2,
set_balance_proposal_hash_and_note(2),
VoteThreshold::SuperMajorityApprove,
0
0,
);
assert_ok!(Democracy::vote(Origin::signed(4), r, big_aye(4)));
assert_ok!(Democracy::vote(Origin::signed(5), r, big_nay(5)));