mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 09:21:05 +00:00
Introduces account existence providers reference counting (#7363)
* Initial draft * Latest changes * Final bits. * Fixes * Fixes * Test fixes * Fix tests * Fix babe tests * Fix * Fix * Fix * Fix * Fix * fix warnings in assets * Fix UI tests * fix line width * Fix * Update frame/system/src/lib.rs Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com> * Update frame/system/src/lib.rs Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com> * Fix * fix unused warnings * Fix * Update frame/system/src/lib.rs Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com> * Update frame/system/src/lib.rs Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com> * Fix * fix slash and comprehensive slash test * fix reserved slash and comprehensive tests * check slash on non-existent account * Revert "Fix UI tests" This reverts commit e0002c0f13442f7d0c95a054a6c515536328a4a0. * Fix * Fix utility tests * keep dispatch error backwards compatible * Fix * Fix * fix ui test * Companion checker shouldn't be so anal. * Fix * Fix * Fix * Apply suggestions from code review Co-authored-by: Alexander Popiak <alexander.popiak@parity.io> * Update frame/balances/src/lib.rs Co-authored-by: Alexander Popiak <alexander.popiak@parity.io> * return correct slash info when failing gracefully * fix missing import * Update frame/system/src/lib.rs Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com> * Fix * Update frame/balances/src/tests_local.rs Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com> * Fixes Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com> Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com> Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com> Co-authored-by: Alexander Popiak <alexander.popiak@parity.io>
This commit is contained in:
@@ -144,7 +144,8 @@ pub struct TestBaseCallFilter;
|
||||
impl Filter<Call> for TestBaseCallFilter {
|
||||
fn filter(c: &Call) -> bool {
|
||||
match *c {
|
||||
Call::Balances(_) => true,
|
||||
// Transfer works. Use `transfer_keep_alive` for a call that doesn't pass the filter.
|
||||
Call::Balances(pallet_balances::Call::transfer(..)) => true,
|
||||
Call::Utility(_) => true,
|
||||
// For benchmarking, this acts as a noop call
|
||||
Call::System(frame_system::Call::remark(..)) => true,
|
||||
@@ -275,7 +276,7 @@ fn as_derivative_filters() {
|
||||
assert_err_ignore_postinfo!(Utility::as_derivative(
|
||||
Origin::signed(1),
|
||||
1,
|
||||
Box::new(Call::System(frame_system::Call::suicide())),
|
||||
Box::new(Call::Balances(pallet_balances::Call::transfer_keep_alive(2, 1))),
|
||||
), DispatchError::BadOrigin);
|
||||
});
|
||||
}
|
||||
@@ -320,7 +321,7 @@ fn batch_with_signed_filters() {
|
||||
new_test_ext().execute_with(|| {
|
||||
assert_ok!(
|
||||
Utility::batch(Origin::signed(1), vec![
|
||||
Call::System(frame_system::Call::suicide())
|
||||
Call::Balances(pallet_balances::Call::transfer_keep_alive(2, 1))
|
||||
]),
|
||||
);
|
||||
expect_event(Event::BatchInterrupted(0, DispatchError::BadOrigin));
|
||||
|
||||
Reference in New Issue
Block a user