Skip to content

Commit

Permalink
Trying to teleport
Browse files Browse the repository at this point in the history
  • Loading branch information
tsenovilla committed Oct 11, 2024
1 parent fb6a612 commit dc518f8
Show file tree
Hide file tree
Showing 3 changed files with 439 additions and 0 deletions.
13 changes: 13 additions & 0 deletions xcm-simulator/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
mod laosish;
mod parachain;
mod relay_chain;
mod parachain_teleporter;

use hex_literal::hex;

Expand All @@ -32,6 +33,7 @@ pub const INITIAL_BALANCE: u128 = 1_000_000_000;

const PARA_A_ID: u32 = 1;
const PARA_B_ID: u32 = 2;
const PARA_TELEPORTER_ID: u32 = 7;
const PARA_LAOSISH_ID: u32 = 3;

decl_test_parachain! {
Expand All @@ -52,6 +54,15 @@ decl_test_parachain! {
}
}

decl_test_parachain! {
pub struct ParaTeleporter {
Runtime = parachain::Runtime,
XcmpMessageHandler = parachain::MsgQueue,
DmpMessageHandler = parachain::MsgQueue,
new_ext = para_ext(PARA_TELEPORTER_ID),
}
}

decl_test_parachain! {
pub struct Laosish {
Runtime = laosish::Runtime,
Expand Down Expand Up @@ -79,6 +90,7 @@ decl_test_network! {
parachains = vec![
(PARA_A_ID, ParaA),
(PARA_B_ID, ParaB),
(PARA_TELEPORTER_ID, ParaTeleporter),
(PARA_LAOSISH_ID, Laosish),
],
}
Expand Down Expand Up @@ -185,6 +197,7 @@ pub fn relay_ext() -> sp_io::TestExternalities {

pub type RelayChainPalletXcm = pallet_xcm::Pallet<relay_chain::Runtime>;
pub type ParachainPalletXcm = pallet_xcm::Pallet<parachain::Runtime>;
pub type ParachainTeleporterPalletXcm = pallet_xcm::Pallet<parachain_teleporter::Runtime>;
pub type LaosishPalletXcm = pallet_xcm::Pallet<laosish::Runtime>;

#[frame_support::pallet]
Expand Down
Loading

0 comments on commit dc518f8

Please sign in to comment.