mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 10:31:03 +00:00
[big refactor] Remove crate aliasing. (#4395)
* Rename: Phase 1. * Unify codec. * Fixing: Phase 2 * Fixing: Phase 3. * Fixing: Phase 4. * Fixing: Phase 5. * Fixing: Phase 6. * Fixing: Phase 7. * Fixing: Phase 8. Tests * Fixing: Phase 9. Tests!!! * Fixing: Phase 10. Moar tests! * Finally done! * More fixes. * Rename primitives:: to sp_core:: * Apply renames in finality-grandpa. * Fix benches. * Fix benches 2. * Revert node-template. * Fix frame-system in our modules.
This commit is contained in:
committed by
Gavin Wood
parent
f14d98a439
commit
8778ca7dc8
@@ -20,13 +20,13 @@
|
||||
|
||||
use super::*;
|
||||
use crate::mock::*;
|
||||
use primitives::offchain::{
|
||||
use sp_core::offchain::{
|
||||
OpaquePeerId,
|
||||
OffchainExt,
|
||||
TransactionPoolExt,
|
||||
testing::{TestOffchainExt, TestTransactionPoolExt},
|
||||
};
|
||||
use support::{dispatch, assert_noop};
|
||||
use frame_support::{dispatch, assert_noop};
|
||||
use sp_runtime::testing::UintAuthorityId;
|
||||
|
||||
#[test]
|
||||
@@ -113,7 +113,7 @@ fn heartbeat(
|
||||
id: UintAuthorityId,
|
||||
) -> dispatch::Result {
|
||||
#[allow(deprecated)]
|
||||
use support::unsigned::ValidateUnsigned;
|
||||
use frame_support::unsigned::ValidateUnsigned;
|
||||
|
||||
let heartbeat = Heartbeat {
|
||||
block_number,
|
||||
@@ -129,7 +129,7 @@ fn heartbeat(
|
||||
#[allow(deprecated)] // Allow ValidateUnsigned
|
||||
ImOnline::pre_dispatch(&crate::Call::heartbeat(heartbeat.clone(), signature.clone()))?;
|
||||
ImOnline::heartbeat(
|
||||
Origin::system(system::RawOrigin::None),
|
||||
Origin::system(frame_system::RawOrigin::None),
|
||||
heartbeat,
|
||||
signature
|
||||
)
|
||||
@@ -262,7 +262,7 @@ fn should_cleanup_received_heartbeats_on_session_end() {
|
||||
|
||||
#[test]
|
||||
fn should_mark_online_validator_when_block_is_authored() {
|
||||
use authorship::EventHandler;
|
||||
use pallet_authorship::EventHandler;
|
||||
|
||||
new_test_ext().execute_with(|| {
|
||||
advance_session();
|
||||
@@ -292,7 +292,7 @@ fn should_mark_online_validator_when_block_is_authored() {
|
||||
|
||||
#[test]
|
||||
fn should_not_send_a_report_if_already_online() {
|
||||
use authorship::EventHandler;
|
||||
use pallet_authorship::EventHandler;
|
||||
|
||||
let mut ext = new_test_ext();
|
||||
let (offchain, _state) = TestOffchainExt::new();
|
||||
@@ -313,7 +313,7 @@ fn should_not_send_a_report_if_already_online() {
|
||||
ImOnline::note_uncle(3, 0);
|
||||
|
||||
// when
|
||||
UintAuthorityId::set_all_keys(vec![0]); // all authorities use session key 0
|
||||
UintAuthorityId::set_all_keys(vec![0]); // all authorities use pallet_session key 0
|
||||
ImOnline::offchain(4);
|
||||
|
||||
// then
|
||||
|
||||
Reference in New Issue
Block a user