Refactor sr_primitives. (#3214)

* refactor sr_primitives.

* Fix try build error.

* Line-width

* Ui test.

* Final fixes.

* Fix build again.

* bring back ui test.

* Fix unsigned import.

* Another ui fix.

* Also refactor substrate-primitives

* Fix benchmarks.

* Fix doc test.

* fix doc tests
This commit is contained in:
Kian Paimani
2019-07-29 14:43:53 +02:00
committed by Bastian Köcher
parent cf80af9255
commit 79feb23a22
259 changed files with 667 additions and 665 deletions
@@ -17,7 +17,7 @@
//! Block Builder extensions for tests.
use runtime;
use runtime_primitives::traits::ProvideRuntimeApi;
use sr_primitives::traits::ProvideRuntimeApi;
use generic_test_client::client;
use generic_test_client::client::block_builder::api::BlockBuilder;
@@ -27,7 +27,7 @@ pub use generic_test_client::*;
pub use runtime;
use runtime::genesismap::{GenesisConfig, additional_storage_with_genesis};
use runtime_primitives::traits::{Block as BlockT, Header as HeaderT, Hash as HashT};
use sr_primitives::traits::{Block as BlockT, Header as HeaderT, Hash as HashT};
/// A prelude to import in tests.
pub mod prelude {
@@ -28,8 +28,8 @@ use crate::{AccountKeyring, ClientExt, TestClientBuilder, TestClientBuilderExt};
use generic_test_client::consensus::BlockOrigin;
use primitives::Blake2Hasher;
use runtime::{self, Transfer};
use runtime_primitives::generic::BlockId;
use runtime_primitives::traits::Block as BlockT;
use sr_primitives::generic::BlockId;
use sr_primitives::traits::Block as BlockT;
/// helper to test the `leaves` implementation for various backends
pub fn test_leaves_for_backend<B: 'static>(backend: Arc<B>) where