Add field names to pallet Event variants (#9993)

* convert pallet-assets events to struct types

* updated events of a couple pallets

* updated pallet event field names

* update pallet event field names

* updated events in test files

* cargo fmt

* minorfixes

* fix assertion error

* minor fix

* formatting fix

* fmt
This commit is contained in:
David Salami
2021-11-16 02:56:00 +01:00
committed by GitHub
parent fb3c7326c2
commit 120894fdb7
48 changed files with 1181 additions and 681 deletions
+3 -3
View File
@@ -172,7 +172,7 @@ benchmarks! {
let bounty_id = BountyCount::<T>::get() - 1;
}: close_bounty(RawOrigin::Root, bounty_id)
verify {
assert_last_event::<T>(Event::BountyCanceled(bounty_id).into())
assert_last_event::<T>(Event::BountyCanceled { index: bounty_id }.into())
}
extend_bounty_expiry {
@@ -184,7 +184,7 @@ benchmarks! {
let curator = T::Lookup::lookup(curator_lookup).map_err(<&str>::from)?;
}: _(RawOrigin::Signed(curator), bounty_id, Vec::new())
verify {
assert_last_event::<T>(Event::BountyExtended(bounty_id).into())
assert_last_event::<T>(Event::BountyExtended { index: bounty_id }.into())
}
spend_funds {
@@ -207,7 +207,7 @@ benchmarks! {
verify {
ensure!(budget_remaining < BalanceOf::<T>::max_value(), "Budget not used");
ensure!(missed_any == false, "Missed some");
assert_last_event::<T>(Event::BountyBecameActive(b - 1).into())
assert_last_event::<T>(Event::BountyBecameActive { index: b - 1 }.into())
}
impl_benchmark_test_suite!(Bounties, crate::tests::new_test_ext(), crate::tests::Test)