mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 23:57:56 +00:00
Rename Origin (#1628)
* Rename Origin
* more renaming
* fixes
* fix errors
* last fix?
* rename
* Update mock.rs
* update lockfile for {"polkadot", "substrate"}
Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>
Co-authored-by: parity-processbot <>
This commit is contained in:
@@ -96,7 +96,7 @@ pub struct RuntimeHelper<Runtime>(PhantomData<Runtime>);
|
||||
impl<Runtime: frame_system::Config> RuntimeHelper<Runtime>
|
||||
where
|
||||
AccountIdOf<Runtime>:
|
||||
Into<<<Runtime as frame_system::Config>::Origin as OriginTrait>::AccountId>,
|
||||
Into<<<Runtime as frame_system::Config>::RuntimeOrigin as OriginTrait>::AccountId>,
|
||||
{
|
||||
pub fn run_to_block(n: u32, author: Option<AccountId>) {
|
||||
while frame_system::Pallet::<Runtime>::block_number() < n.into() {
|
||||
@@ -122,13 +122,13 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
pub fn root_origin() -> <Runtime as frame_system::Config>::Origin {
|
||||
<Runtime as frame_system::Config>::Origin::root()
|
||||
pub fn root_origin() -> <Runtime as frame_system::Config>::RuntimeOrigin {
|
||||
<Runtime as frame_system::Config>::RuntimeOrigin::root()
|
||||
}
|
||||
|
||||
pub fn origin_of(
|
||||
account_id: AccountIdOf<Runtime>,
|
||||
) -> <Runtime as frame_system::Config>::Origin {
|
||||
<Runtime as frame_system::Config>::Origin::signed(account_id.into())
|
||||
) -> <Runtime as frame_system::Config>::RuntimeOrigin {
|
||||
<Runtime as frame_system::Config>::RuntimeOrigin::signed(account_id.into())
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user