mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-12 17:01:09 +00:00
Normalize Crate Names in SRML/Node Template (#3543)
* Fix some instances of `runtime-io` * Patch a bunch * More patches for consistancy * more patch * Fix various build issues * Fix tests * Patch `srml-support-*` crates * Fix doc tests * Revert "Fix doc tests" This reverts commit ba2ec61da7acc36821a70e76a31a6a5bf13bbe95. * Revert "Patch `srml-support-*` crates" This reverts commit 9a6070450107dec17784ba34af4b871023f6dc81. * Missed one * Fix doc tests
This commit is contained in:
@@ -7,12 +7,12 @@ edition = "2018"
|
||||
[dependencies]
|
||||
serde = { version = "1.0", optional = true }
|
||||
codec = { package = "parity-scale-codec", version = "1.0.0", default-features = false }
|
||||
srml-support = { path = "../support", default-features = false }
|
||||
support = { package = "srml-support", path = "../support", default-features = false }
|
||||
system = { package = "srml-system", path = "../system", default-features = false }
|
||||
balances = { package = "srml-balances", path = "../balances", default-features = false }
|
||||
sr-primitives = { path = "../../core/sr-primitives", default-features = false }
|
||||
rstd = { package = "sr-std", path = "../../core/sr-std", default-features = false }
|
||||
rio = { package = "sr-io", path = "../../core/sr-io", default-features = false }
|
||||
runtime-io = { package = "sr-io", path = "../../core/sr-io", default-features = false }
|
||||
|
||||
[dev-dependencies]
|
||||
primitives = { package = "substrate-primitives", path = "../../core/primitives" }
|
||||
@@ -23,9 +23,9 @@ std = [
|
||||
"serde",
|
||||
"codec/std",
|
||||
"sr-primitives/std",
|
||||
"srml-support/std",
|
||||
"support/std",
|
||||
"system/std",
|
||||
"balances/std",
|
||||
"rio/std",
|
||||
"runtime-io/std",
|
||||
"rstd/std"
|
||||
]
|
||||
|
||||
@@ -254,7 +254,7 @@
|
||||
#![cfg_attr(not(feature = "std"), no_std)]
|
||||
|
||||
use rstd::marker::PhantomData;
|
||||
use srml_support::{StorageValue, dispatch::Result, decl_module, decl_storage, decl_event};
|
||||
use support::{StorageValue, dispatch::Result, decl_module, decl_storage, decl_event};
|
||||
use system::{ensure_signed, ensure_root};
|
||||
use codec::{Encode, Decode};
|
||||
use sr_primitives::{
|
||||
@@ -576,7 +576,7 @@ impl<T: Trait + Send + Sync> SignedExtension for WatchDummy<T> {
|
||||
// check for `set_dummy`
|
||||
match call {
|
||||
Call::set_dummy(..) => {
|
||||
rio::print("set_dummy was received.");
|
||||
runtime_io::print("set_dummy was received.");
|
||||
|
||||
let mut valid_tx = ValidTransaction::default();
|
||||
valid_tx.priority = Bounded::max_value();
|
||||
@@ -591,8 +591,8 @@ impl<T: Trait + Send + Sync> SignedExtension for WatchDummy<T> {
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
||||
use srml_support::{assert_ok, impl_outer_origin, parameter_types};
|
||||
use rio::with_externalities;
|
||||
use support::{assert_ok, impl_outer_origin, parameter_types};
|
||||
use runtime_io::with_externalities;
|
||||
use primitives::{H256, Blake2Hasher};
|
||||
// The testing primitives are very useful for avoiding having to work with signatures
|
||||
// or public keys. `u64` is used as the `AccountId` and no `Signature`s are required.
|
||||
@@ -662,7 +662,7 @@ mod tests {
|
||||
|
||||
// This function basically just builds a genesis storage key/value store according to
|
||||
// our desired mockup.
|
||||
fn new_test_ext() -> rio::TestExternalities<Blake2Hasher> {
|
||||
fn new_test_ext() -> runtime_io::TestExternalities<Blake2Hasher> {
|
||||
let mut t = system::GenesisConfig::default().build_storage::<Test>().unwrap();
|
||||
// We use default for brevity, but you can configure as desired if needed.
|
||||
balances::GenesisConfig::<Test>::default().assimilate_storage(&mut t).unwrap();
|
||||
|
||||
Reference in New Issue
Block a user