Companion for #11981 (#1563)

* Companion for #11981

* rename

* Event to RuntimeEvent in imports

* missed rename

* undo

* revert

* rename type Call & Event

* commit

* ...

* fix

* fix errors

* fixes

* fmt

* fix imports

* final fix?

* fmt

* fix?

* fixes after merge

* small fix

* cargo update -p polkadot-runtime-common

* cargo +nightly fmt

* update lockfile for {"polkadot", "substrate"}

* fix

Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>
Co-authored-by: parity-processbot <>
This commit is contained in:
Sergej Sakac
2022-09-13 01:55:33 +02:00
committed by GitHub
parent 51eb647826
commit b43bc58cb6
39 changed files with 1020 additions and 958 deletions
+6 -4
View File
@@ -19,7 +19,7 @@
mod block_builder;
use codec::{Decode, Encode};
use runtime::{
Balance, Block, BlockHashCount, Call, GenesisConfig, Runtime, Signature, SignedExtra,
Balance, Block, BlockHashCount, GenesisConfig, Runtime, RuntimeCall, Signature, SignedExtra,
SignedPayload, UncheckedExtrinsic, VERSION,
};
use sc_executor::{WasmExecutionMethod, WasmExecutor};
@@ -122,7 +122,7 @@ fn genesis_config() -> GenesisConfig {
pub fn generate_extrinsic(
client: &Client,
origin: sp_keyring::AccountKeyring,
function: impl Into<Call>,
function: impl Into<RuntimeCall>,
) -> UncheckedExtrinsic {
let current_block_hash = client.info().best_hash;
let current_block = client.info().best_number.saturated_into();
@@ -165,8 +165,10 @@ pub fn transfer(
dest: sp_keyring::AccountKeyring,
value: Balance,
) -> UncheckedExtrinsic {
let function =
Call::Balances(pallet_balances::Call::transfer { dest: dest.public().into(), value });
let function = RuntimeCall::Balances(pallet_balances::Call::transfer {
dest: dest.public().into(),
value,
});
generate_extrinsic(client, origin, function)
}