Bump Substrate (#871)

* Bump Substrate

* Change usage of "Module" to "Pallet"

Related Substrate PR: https://github.com/paritytech/substrate/pull/8372

* Add `OnSetCode` config param

Related Substrate PR: https://github.com/paritytech/substrate/pull/8496

* Update Aura Slot duration time type

Related Substrate PR: https://github.com/paritytech/substrate/pull/8386

* Add `OnSetCode` to mock runtimes

* Add support for multiple justifications

Related Substrate PR: https://github.com/paritytech/substrate/pull/7640

* Use updated justification type in more places

* Make GenesisConfig type non-optional

Related Substrate PR: https://github.com/paritytech/substrate/pull/8275

* Update service to use updated telemetry

Related Substrate PR: https://github.com/paritytech/substrate/pull/8143

* Appease Clippy
This commit is contained in:
Hernando Castano
2021-04-07 11:56:45 -04:00
committed by Bastian Köcher
parent d9c553374c
commit c6ae74725b
32 changed files with 501 additions and 395 deletions
+14 -14
View File
@@ -122,7 +122,7 @@ impl Alternative {
get_account_id_from_seed::<sr25519::Public>("Ferdie//stash"),
get_account_id_from_seed::<sr25519::Public>("George//stash"),
get_account_id_from_seed::<sr25519::Public>("Harry//stash"),
pallet_bridge_messages::Module::<
pallet_bridge_messages::Pallet::<
rialto_runtime::Runtime,
pallet_bridge_messages::DefaultInstance,
>::relayer_fund_account_id(),
@@ -154,28 +154,28 @@ fn testnet_genesis(
_enable_println: bool,
) -> GenesisConfig {
GenesisConfig {
frame_system: Some(SystemConfig {
frame_system: SystemConfig {
code: WASM_BINARY.to_vec(),
changes_trie_config: Default::default(),
}),
pallet_balances: Some(BalancesConfig {
},
pallet_balances: BalancesConfig {
balances: endowed_accounts.iter().cloned().map(|k| (k, 1 << 50)).collect(),
}),
pallet_aura: Some(AuraConfig {
},
pallet_aura: AuraConfig {
authorities: Vec::new(),
}),
pallet_bridge_eth_poa_Instance1: Some(load_rialto_poa_bridge_config()),
pallet_bridge_eth_poa_Instance2: Some(load_kovan_bridge_config()),
pallet_grandpa: Some(GrandpaConfig {
},
pallet_bridge_eth_poa_Instance1: load_rialto_poa_bridge_config(),
pallet_bridge_eth_poa_Instance2: load_kovan_bridge_config(),
pallet_grandpa: GrandpaConfig {
authorities: Vec::new(),
}),
pallet_sudo: Some(SudoConfig { key: root_key }),
pallet_session: Some(SessionConfig {
},
pallet_sudo: SudoConfig { key: root_key },
pallet_session: SessionConfig {
keys: initial_authorities
.iter()
.map(|x| (x.0.clone(), x.0.clone(), session_keys(x.1.clone(), x.2.clone())))
.collect::<Vec<_>>(),
}),
},
}
}
+100 -56
View File
@@ -30,11 +30,13 @@
use rialto_runtime::{self, opaque::Block, RuntimeApi};
use sc_client_api::{ExecutorProvider, RemoteBackend};
use sc_consensus_aura::{ImportQueueParams, SlotProportion, StartAuraParams};
use sc_executor::native_executor_instance;
pub use sc_executor::NativeExecutor;
use sc_finality_grandpa::SharedVoterState;
use sc_keystore::LocalKeystore;
use sc_service::{error::Error as ServiceError, Configuration, TaskManager};
use sc_telemetry::{Telemetry, TelemetryWorker};
use sp_consensus_aura::sr25519::AuthorityPair as AuraPair;
use sp_inherents::InherentDataProviders;
use std::sync::Arc;
@@ -70,6 +72,7 @@ pub fn new_partial(
AuraPair,
>,
sc_finality_grandpa::LinkHalf<Block, FullClient, FullSelectChain>,
Option<Telemetry>,
),
>,
ServiceError,
@@ -77,12 +80,30 @@ pub fn new_partial(
if config.keystore_remote.is_some() {
return Err(ServiceError::Other("Remote Keystores are not supported.".to_string()));
}
let inherent_data_providers = sp_inherents::InherentDataProviders::new();
let inherent_data_providers = InherentDataProviders::new();
let (client, backend, keystore_container, task_manager) =
sc_service::new_full_parts::<Block, RuntimeApi, Executor>(&config)?;
let telemetry = config
.telemetry_endpoints
.clone()
.filter(|x| !x.is_empty())
.map(|endpoints| -> Result<_, sc_telemetry::Error> {
let worker = TelemetryWorker::new(16)?;
let telemetry = worker.handle().new_telemetry(endpoints);
Ok((worker, telemetry))
})
.transpose()?;
let (client, backend, keystore_container, task_manager) = sc_service::new_full_parts::<Block, RuntimeApi, Executor>(
&config,
telemetry.as_ref().map(|(_, telemetry)| telemetry.handle()),
)?;
let client = Arc::new(client);
let telemetry = telemetry.map(|(worker, telemetry)| {
task_manager.spawn_handle().spawn("telemetry", worker.run());
telemetry
});
let select_chain = sc_consensus::LongestChain::new(backend.clone());
let transaction_pool = sc_transaction_pool::BasicPool::new_full(
@@ -93,22 +114,28 @@ pub fn new_partial(
client.clone(),
);
let (grandpa_block_import, grandpa_link) =
sc_finality_grandpa::block_import(client.clone(), &(client.clone() as Arc<_>), select_chain.clone())?;
let (grandpa_block_import, grandpa_link) = sc_finality_grandpa::block_import(
client.clone(),
&(client.clone() as Arc<_>),
select_chain.clone(),
telemetry.as_ref().map(|x| x.handle()),
)?;
let aura_block_import =
sc_consensus_aura::AuraBlockImport::<_, _, _, AuraPair>::new(grandpa_block_import.clone(), client.clone());
let import_queue = sc_consensus_aura::import_queue::<_, _, _, AuraPair, _, _>(
sc_consensus_aura::slot_duration(&*client)?,
aura_block_import.clone(),
Some(Box::new(grandpa_block_import)),
client.clone(),
inherent_data_providers.clone(),
&task_manager.spawn_essential_handle(),
config.prometheus_registry(),
sp_consensus::CanAuthorWithNativeVersion::new(client.executor().clone()),
)?;
let import_queue = sc_consensus_aura::import_queue::<AuraPair, _, _, _, _, _>(ImportQueueParams {
block_import: aura_block_import.clone(),
justification_import: Some(Box::new(grandpa_block_import)),
client: client.clone(),
inherent_data_providers: inherent_data_providers.clone(),
spawner: &task_manager.spawn_essential_handle(),
can_author_with: sp_consensus::CanAuthorWithNativeVersion::new(client.executor().clone()),
slot_duration: sc_consensus_aura::slot_duration(&*client)?,
registry: config.prometheus_registry(),
check_for_equivocation: Default::default(),
telemetry: telemetry.as_ref().map(|x| x.handle()),
})?;
Ok(sc_service::PartialComponents {
client,
@@ -119,7 +146,7 @@ pub fn new_partial(
select_chain,
transaction_pool,
inherent_data_providers,
other: (aura_block_import, grandpa_link),
other: (aura_block_import, grandpa_link, telemetry),
})
}
@@ -141,7 +168,7 @@ pub fn new_full(mut config: Configuration) -> Result<TaskManager, ServiceError>
select_chain,
transaction_pool,
inherent_data_providers,
other: (block_import, grandpa_link),
other: (block_import, grandpa_link, mut telemetry),
} = new_partial(&config)?;
if let Some(url) = &config.keystore_remote {
@@ -173,13 +200,7 @@ pub fn new_full(mut config: Configuration) -> Result<TaskManager, ServiceError>
})?;
if config.offchain_worker.enabled {
sc_service::build_offchain_workers(
&config,
backend.clone(),
task_manager.spawn_handle(),
client.clone(),
network.clone(),
);
sc_service::build_offchain_workers(&config, task_manager.spawn_handle(), client.clone(), network.clone());
}
let role = config.role.clone();
@@ -266,7 +287,7 @@ pub fn new_full(mut config: Configuration) -> Result<TaskManager, ServiceError>
})
};
let (_rpc_handlers, telemetry_connection_notifier) = sc_service::spawn_tasks(sc_service::SpawnTasksParams {
let _rpc_handlers = sc_service::spawn_tasks(sc_service::SpawnTasksParams {
network: network.clone(),
client: client.clone(),
keystore: keystore_container.sync_keystore(),
@@ -279,32 +300,35 @@ pub fn new_full(mut config: Configuration) -> Result<TaskManager, ServiceError>
network_status_sinks,
system_rpc_tx,
config,
telemetry_span: None,
telemetry: telemetry.as_mut(),
})?;
if role.is_authority() {
let proposer = sc_basic_authorship::ProposerFactory::new(
let proposer_factory = sc_basic_authorship::ProposerFactory::new(
task_manager.spawn_handle(),
client.clone(),
transaction_pool,
prometheus_registry.as_ref(),
telemetry.as_ref().map(|x| x.handle()),
);
let can_author_with = sp_consensus::CanAuthorWithNativeVersion::new(client.executor().clone());
let aura = sc_consensus_aura::start_aura::<_, _, _, _, _, AuraPair, _, _, _, _>(
sc_consensus_aura::slot_duration(&*client)?,
client.clone(),
let aura = sc_consensus_aura::start_aura::<AuraPair, _, _, _, _, _, _, _, _, _>(StartAuraParams {
slot_duration: sc_consensus_aura::slot_duration(&*client)?,
client: client.clone(),
select_chain,
block_import,
proposer,
network.clone(),
proposer_factory,
inherent_data_providers,
force_authoring,
backoff_authoring_blocks,
keystore_container.sync_keystore(),
keystore: keystore_container.sync_keystore(),
can_author_with,
)?;
sync_oracle: network.clone(),
block_proposal_slot_portion: SlotProportion::new(2f32 / 3f32),
telemetry: telemetry.as_ref().map(|x| x.handle()),
})?;
// the AURA authoring task is considered essential, i.e. if it
// fails we take down the service with it.
@@ -327,6 +351,7 @@ pub fn new_full(mut config: Configuration) -> Result<TaskManager, ServiceError>
observer_enabled: false,
keystore,
is_authority: role.is_authority(),
telemetry: telemetry.as_ref().map(|x| x.handle()),
};
if enable_grandpa {
@@ -340,10 +365,10 @@ pub fn new_full(mut config: Configuration) -> Result<TaskManager, ServiceError>
config: grandpa_config,
link: grandpa_link,
network,
telemetry_on_connect: telemetry_connection_notifier.map(|x| x.on_connect_stream()),
voting_rule: sc_finality_grandpa::VotingRulesBuilder::default().build(),
prometheus_registry,
shared_voter_state: SharedVoterState::empty(),
telemetry: telemetry.as_ref().map(|x| x.handle()),
};
// the GRANDPA voter task is considered infallible, i.e.
@@ -359,8 +384,27 @@ pub fn new_full(mut config: Configuration) -> Result<TaskManager, ServiceError>
/// Builds a new service for a light client.
pub fn new_light(mut config: Configuration) -> Result<TaskManager, ServiceError> {
let telemetry = config
.telemetry_endpoints
.clone()
.filter(|x| !x.is_empty())
.map(|endpoints| -> Result<_, sc_telemetry::Error> {
let worker = TelemetryWorker::new(16)?;
let telemetry = worker.handle().new_telemetry(endpoints);
Ok((worker, telemetry))
})
.transpose()?;
let (client, backend, keystore_container, mut task_manager, on_demand) =
sc_service::new_light_parts::<Block, RuntimeApi, Executor>(&config)?;
sc_service::new_light_parts::<Block, RuntimeApi, Executor>(
&config,
telemetry.as_ref().map(|(_, telemetry)| telemetry.handle()),
)?;
let mut telemetry = telemetry.map(|(worker, telemetry)| {
task_manager.spawn_handle().spawn("telemetry", worker.run());
telemetry
});
config
.network
@@ -377,22 +421,28 @@ pub fn new_light(mut config: Configuration) -> Result<TaskManager, ServiceError>
on_demand.clone(),
));
let (grandpa_block_import, _) =
sc_finality_grandpa::block_import(client.clone(), &(client.clone() as Arc<_>), select_chain)?;
let (grandpa_block_import, _) = sc_finality_grandpa::block_import(
client.clone(),
&(client.clone() as Arc<_>),
select_chain,
telemetry.as_ref().map(|x| x.handle()),
)?;
let aura_block_import =
sc_consensus_aura::AuraBlockImport::<_, _, _, AuraPair>::new(grandpa_block_import.clone(), client.clone());
let import_queue = sc_consensus_aura::import_queue::<_, _, _, AuraPair, _, _>(
sc_consensus_aura::slot_duration(&*client)?,
aura_block_import,
Some(Box::new(grandpa_block_import)),
client.clone(),
InherentDataProviders::new(),
&task_manager.spawn_essential_handle(),
config.prometheus_registry(),
sp_consensus::NeverCanAuthor,
)?;
let import_queue = sc_consensus_aura::import_queue::<AuraPair, _, _, _, _, _>(ImportQueueParams {
block_import: aura_block_import,
justification_import: Some(Box::new(grandpa_block_import)),
client: client.clone(),
inherent_data_providers: InherentDataProviders::new(),
spawner: &task_manager.spawn_essential_handle(),
can_author_with: sp_consensus::NeverCanAuthor,
slot_duration: sc_consensus_aura::slot_duration(&*client)?,
registry: config.prometheus_registry(),
check_for_equivocation: Default::default(),
telemetry: telemetry.as_ref().map(|x| x.handle()),
})?;
let (network, network_status_sinks, system_rpc_tx, network_starter) =
sc_service::build_network(sc_service::BuildNetworkParams {
@@ -406,13 +456,7 @@ pub fn new_light(mut config: Configuration) -> Result<TaskManager, ServiceError>
})?;
if config.offchain_worker.enabled {
sc_service::build_offchain_workers(
&config,
backend.clone(),
task_manager.spawn_handle(),
client.clone(),
network.clone(),
);
sc_service::build_offchain_workers(&config, task_manager.spawn_handle(), client.clone(), network.clone());
}
sc_service::spawn_tasks(sc_service::SpawnTasksParams {
@@ -428,7 +472,7 @@ pub fn new_light(mut config: Configuration) -> Result<TaskManager, ServiceError>
network,
network_status_sinks,
system_rpc_tx,
telemetry_span: None,
telemetry: telemetry.as_mut(),
})?;
network_starter.start_network();
+38 -36
View File
@@ -208,6 +208,8 @@ impl frame_system::Config for Runtime {
type DbWeight = DbWeight;
/// The designated SS58 prefix of this chain.
type SS58Prefix = SS58Prefix;
/// The set code logic, just the default since we're not a parachain.
type OnSetCode = ();
}
impl pallet_aura::Config for Runtime {
@@ -277,7 +279,7 @@ impl bp_currency_exchange::DepositInto for DepositInto {
fn deposit_into(recipient: Self::Recipient, amount: Self::Amount) -> bp_currency_exchange::Result<()> {
// let balances module make all checks for us (it won't allow depositing lower than existential
// deposit, balance overflow, ...)
let deposited = <pallet_balances::Module<Runtime> as Currency<AccountId>>::deposit_creating(&recipient, amount);
let deposited = <pallet_balances::Pallet<Runtime> as Currency<AccountId>>::deposit_creating(&recipient, amount);
// I'm dropping deposited here explicitly to illustrate the fact that it'll update `TotalIssuance`
// on drop
@@ -398,7 +400,7 @@ impl pallet_session::Config for Runtime {
type ValidatorIdOf = ();
type ShouldEndSession = pallet_session::PeriodicSessions<Period, Offset>;
type NextSessionRotation = pallet_session::PeriodicSessions<Period, Offset>;
type SessionManager = pallet_shift_session_manager::Module<Runtime>;
type SessionManager = pallet_shift_session_manager::Pallet<Runtime>;
type SessionHandler = <SessionKeys as OpaqueKeys>::KeyTypeIdProviders;
type Keys = SessionKeys;
type DisabledValidatorsThreshold = ();
@@ -456,7 +458,7 @@ impl pallet_bridge_messages::Config for Runtime {
type LaneMessageVerifier = crate::millau_messages::ToMillauMessageVerifier;
type MessageDeliveryAndDispatchPayment = pallet_bridge_messages::instant_payments::InstantCurrencyPayments<
Runtime,
pallet_balances::Module<Runtime>,
pallet_balances::Pallet<Runtime>,
GetDeliveryConfirmationTransactionFee,
RootAccountForPayments,
>;
@@ -471,23 +473,23 @@ construct_runtime!(
NodeBlock = opaque::Block,
UncheckedExtrinsic = UncheckedExtrinsic
{
BridgeRialtoPoA: pallet_bridge_eth_poa::<Instance1>::{Module, Call, Config, Storage, ValidateUnsigned},
BridgeKovan: pallet_bridge_eth_poa::<Instance2>::{Module, Call, Config, Storage, ValidateUnsigned},
BridgeRialtoCurrencyExchange: pallet_bridge_currency_exchange::<Instance1>::{Module, Call},
BridgeKovanCurrencyExchange: pallet_bridge_currency_exchange::<Instance2>::{Module, Call},
BridgeMillauGrandpa: pallet_bridge_grandpa::{Module, Call, Storage},
BridgeDispatch: pallet_bridge_dispatch::{Module, Event<T>},
BridgeMillauMessages: pallet_bridge_messages::{Module, Call, Storage, Event<T>},
System: frame_system::{Module, Call, Config, Storage, Event<T>},
RandomnessCollectiveFlip: pallet_randomness_collective_flip::{Module, Call, Storage},
Timestamp: pallet_timestamp::{Module, Call, Storage, Inherent},
Aura: pallet_aura::{Module, Config<T>},
Grandpa: pallet_grandpa::{Module, Call, Storage, Config, Event},
Balances: pallet_balances::{Module, Call, Storage, Config<T>, Event<T>},
TransactionPayment: pallet_transaction_payment::{Module, Storage},
Sudo: pallet_sudo::{Module, Call, Config<T>, Storage, Event<T>},
Session: pallet_session::{Module, Call, Storage, Event, Config<T>},
ShiftSessionManager: pallet_shift_session_manager::{Module},
BridgeRialtoPoA: pallet_bridge_eth_poa::<Instance1>::{Pallet, Call, Config, Storage, ValidateUnsigned},
BridgeKovan: pallet_bridge_eth_poa::<Instance2>::{Pallet, Call, Config, Storage, ValidateUnsigned},
BridgeRialtoCurrencyExchange: pallet_bridge_currency_exchange::<Instance1>::{Pallet, Call},
BridgeKovanCurrencyExchange: pallet_bridge_currency_exchange::<Instance2>::{Pallet, Call},
BridgeMillauGrandpa: pallet_bridge_grandpa::{Pallet, Call, Storage},
BridgeDispatch: pallet_bridge_dispatch::{Pallet, Event<T>},
BridgeMillauMessages: pallet_bridge_messages::{Pallet, Call, Storage, Event<T>},
System: frame_system::{Pallet, Call, Config, Storage, Event<T>},
RandomnessCollectiveFlip: pallet_randomness_collective_flip::{Pallet, Call, Storage},
Timestamp: pallet_timestamp::{Pallet, Call, Storage, Inherent},
Aura: pallet_aura::{Pallet, Config<T>},
Grandpa: pallet_grandpa::{Pallet, Call, Storage, Config, Event},
Balances: pallet_balances::{Pallet, Call, Storage, Config<T>, Event<T>},
TransactionPayment: pallet_transaction_payment::{Pallet, Storage},
Sudo: pallet_sudo::{Pallet, Call, Config<T>, Storage, Event<T>},
Session: pallet_session::{Pallet, Call, Storage, Event, Config<T>},
ShiftSessionManager: pallet_shift_session_manager::{Pallet},
}
);
@@ -519,7 +521,7 @@ pub type UncheckedExtrinsic = generic::UncheckedExtrinsic<Address, Call, Signatu
pub type CheckedExtrinsic = generic::CheckedExtrinsic<AccountId, Call, SignedExtra>;
/// Executive: handles dispatch to the various modules.
pub type Executive =
frame_executive::Executive<Runtime, Block, frame_system::ChainContext<Runtime>, Runtime, AllModules>;
frame_executive::Executive<Runtime, Block, frame_system::ChainContext<Runtime>, Runtime, AllPallets>;
impl_runtime_apis! {
impl sp_api::Core<Block> for Runtime {
@@ -563,7 +565,7 @@ impl_runtime_apis! {
}
fn random_seed() -> <Block as BlockT>::Hash {
RandomnessCollectiveFlip::random_seed().0.into()
RandomnessCollectiveFlip::random_seed().0
}
}
@@ -652,8 +654,8 @@ impl_runtime_apis! {
}
impl sp_consensus_aura::AuraApi<Block, AuraId> for Runtime {
fn slot_duration() -> u64 {
Aura::slot_duration()
fn slot_duration() -> sp_consensus_aura::SlotDuration {
sp_consensus_aura::SlotDuration::from_millis(Aura::slot_duration())
}
fn authorities() -> Vec<AuraId> {
@@ -789,7 +791,7 @@ impl_runtime_apis! {
let params = (&config, &whitelist);
use pallet_bridge_currency_exchange::benchmarking::{
Module as BridgeCurrencyExchangeBench,
Pallet as BridgeCurrencyExchangeBench,
Config as BridgeCurrencyExchangeConfig,
ProofParams as BridgeCurrencyExchangeProofParams,
};
@@ -831,7 +833,7 @@ impl_runtime_apis! {
use crate::millau_messages::{ToMillauMessagePayload, WithMillauMessageBridge};
use bridge_runtime_common::messages;
use pallet_bridge_messages::benchmarking::{
Module as MessagesBench,
Pallet as MessagesBench,
Config as MessagesConfig,
MessageDeliveryProofParams,
MessageParams,
@@ -849,11 +851,11 @@ impl_runtime_apis! {
}
fn account_balance(account: &Self::AccountId) -> Self::OutboundMessageFee {
pallet_balances::Module::<Runtime>::free_balance(account)
pallet_balances::Pallet::<Runtime>::free_balance(account)
}
fn endow_account(account: &Self::AccountId) {
pallet_balances::Module::<Runtime>::make_free_balance_be(
pallet_balances::Pallet::<Runtime>::make_free_balance_be(
account,
Balance::MAX / 100,
);
@@ -1033,7 +1035,7 @@ mod tests {
ext.execute_with(|| {
// initially issuance is zero
assert_eq!(
<pallet_balances::Module<Runtime> as Currency<AccountId>>::total_issuance(),
<pallet_balances::Pallet<Runtime> as Currency<AccountId>>::total_issuance(),
0,
);
@@ -1041,14 +1043,14 @@ mod tests {
let account: AccountId = [1u8; 32].into();
let initial_amount = ExistentialDeposit::get();
let deposited =
<pallet_balances::Module<Runtime> as Currency<AccountId>>::deposit_creating(&account, initial_amount);
<pallet_balances::Pallet<Runtime> as Currency<AccountId>>::deposit_creating(&account, initial_amount);
drop(deposited);
assert_eq!(
<pallet_balances::Module<Runtime> as Currency<AccountId>>::total_issuance(),
<pallet_balances::Pallet<Runtime> as Currency<AccountId>>::total_issuance(),
initial_amount,
);
assert_eq!(
<pallet_balances::Module<Runtime> as Currency<AccountId>>::free_balance(&account),
<pallet_balances::Pallet<Runtime> as Currency<AccountId>>::free_balance(&account),
initial_amount,
);
@@ -1057,7 +1059,7 @@ mod tests {
// check that total issuance has changed by `run_deposit_into_test`
assert_eq!(
<pallet_balances::Module<Runtime> as Currency<AccountId>>::total_issuance(),
<pallet_balances::Pallet<Runtime> as Currency<AccountId>>::total_issuance(),
initial_amount + total_issuance_change,
);
});
@@ -1101,7 +1103,7 @@ mod tests {
fn deposit_into_existing_account_works() {
run_deposit_into_test(|existing_account| {
let initial_amount =
<pallet_balances::Module<Runtime> as Currency<AccountId>>::free_balance(&existing_account);
<pallet_balances::Pallet<Runtime> as Currency<AccountId>>::free_balance(&existing_account);
let additional_amount = 10_000;
<Runtime as pallet_bridge_currency_exchange::Config<KovanCurrencyExchange>>::DepositInto::deposit_into(
existing_account.clone(),
@@ -1109,7 +1111,7 @@ mod tests {
)
.unwrap();
assert_eq!(
<pallet_balances::Module<Runtime> as Currency<AccountId>>::free_balance(&existing_account),
<pallet_balances::Pallet<Runtime> as Currency<AccountId>>::free_balance(&existing_account),
initial_amount + additional_amount,
);
additional_amount
@@ -1128,7 +1130,7 @@ mod tests {
)
.unwrap();
assert_eq!(
<pallet_balances::Module<Runtime> as Currency<AccountId>>::free_balance(&new_account),
<pallet_balances::Pallet<Runtime> as Currency<AccountId>>::free_balance(&new_account),
initial_amount + additional_amount,
);
additional_amount