Refactoring Checkpoint: (WIP)

This commit is contained in:
2025-12-14 10:29:31 +03:00
parent 09735eb97a
commit c89d7cac55
1424 changed files with 6415 additions and 6064 deletions
+2 -2
View File
@@ -27,7 +27,7 @@ serde = { features = ["alloc", "derive", "rc"], workspace = true }
pezsp-runtime = { workspace = true }
pezsp-weights = { features = ["serde"], workspace = true }
tracing = { workspace = true }
xcm-procedural = { workspace = true, default-features = true }
xcm-pez-procedural = { workspace = true, default-features = true }
[dev-dependencies]
pezsp-io = { workspace = true, default-features = true }
@@ -55,5 +55,5 @@ runtime-benchmarks = [
"pezframe-support/runtime-benchmarks",
"pezsp-io/runtime-benchmarks",
"pezsp-runtime/runtime-benchmarks",
"xcm-procedural/runtime-benchmarks",
"xcm-pez-procedural/runtime-benchmarks",
]
+4 -4
View File
@@ -1,5 +1,5 @@
[package]
name = "xcm-docs"
name = "xcm-pez-docs"
description = "Documentation and guides for XCM"
version = "0.1.0"
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
@@ -7,7 +7,7 @@ repository.workspace = true
authors.workspace = true
edition.workspace = true
publish = false
documentation = "https://docs.rs/xcm-docs"
documentation = "https://docs.rs/xcm-pez-docs"
homepage = { workspace = true }
[dependencies]
@@ -16,7 +16,7 @@ pezpallet-xcm = { workspace = true, default-features = true }
xcm = { workspace = true, default-features = true }
xcm-builder = { workspace = true, default-features = true }
xcm-executor = { workspace = true, default-features = true }
xcm-simulator = { workspace = true, default-features = true }
xcm-pez-simulator = { workspace = true, default-features = true }
# For building FRAME runtimes
codec = { workspace = true, default-features = true }
@@ -48,6 +48,6 @@ runtime-benchmarks = [
"pezsp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
"xcm-executor/runtime-benchmarks",
"xcm-simulator/runtime-benchmarks",
"xcm-pez-simulator/runtime-benchmarks",
"xcm/runtime-benchmarks",
]
@@ -22,7 +22,7 @@ use frame::deps::{
pezsp_io::TestExternalities,
pezsp_runtime::{AccountId32, BuildStorage},
};
use xcm_simulator::{decl_test_network, decl_test_relay_chain, decl_test_teyrchain, TestExt};
use xcm_pez_simulator::{decl_test_network, decl_test_relay_chain, decl_test_teyrchain, TestExt};
use super::{relay_chain, teyrchain};
@@ -128,7 +128,7 @@ pub type LocalOriginToLocation = SignedToAccountId32<RuntimeOrigin, AccountId, T
impl pezpallet_xcm::Config for Runtime {
// No one can call `send`
type SendXcmOrigin = EnsureXcmOrigin<RuntimeOrigin, ()>;
type XcmRouter = super::super::network::RelayChainXcmRouter; // Provided by xcm-simulator
type XcmRouter = super::super::network::RelayChainXcmRouter; // Provided by xcm-pez-simulator
// Anyone can execute XCM programs
type ExecuteXcmOrigin = EnsureXcmOrigin<RuntimeOrigin, LocalOriginToLocation>;
// We execute any type of program
@@ -19,7 +19,7 @@ use frame::testing_prelude::*;
use test_log::test;
use xcm::prelude::*;
use xcm_executor::traits::{ConvertLocation, TransferType};
use xcm_simulator::TestExt;
use xcm_pez_simulator::TestExt;
use super::{
network::{MockNet, ParaA, Relay, ALICE, BOB, CENTS, INITIAL_BALANCE},
@@ -19,7 +19,7 @@
use frame::{deps::pezframe_system, runtime::prelude::*, traits::IdentityLookup};
use xcm_executor::XcmExecutor;
use xcm_simulator::mock_message_queue;
use xcm_pez_simulator::mock_message_queue;
mod xcm_config;
use xcm_config::XcmConfig;
@@ -155,7 +155,7 @@ pub type LocalOriginToLocation = SignedToAccountId32<RuntimeOrigin, AccountId, T
impl pezpallet_xcm::Config for Runtime {
// We turn off sending for these tests
type SendXcmOrigin = EnsureXcmOrigin<RuntimeOrigin, ()>;
type XcmRouter = super::super::network::TeyrchainXcmRouter<MessageQueue>; // Provided by xcm-simulator
type XcmRouter = super::super::network::TeyrchainXcmRouter<MessageQueue>; // Provided by xcm-pez-simulator
// Anyone can execute XCM programs
type ExecuteXcmOrigin = EnsureXcmOrigin<RuntimeOrigin, LocalOriginToLocation>;
// We execute any type of program
+1 -1
View File
@@ -47,7 +47,7 @@
//! configurable.
//! - [`Builder`](xcm_builder): A collection of types used to configure the executor.
//! - [`XCM Pallet`](pezpallet_xcm): A FRAME pallet for interacting with the executor.
//! - [`Simulator`](xcm_simulator): A playground to tinker with different XCM programs and executor
//! - [`Simulator`](xcm_pez_simulator): A playground to tinker with different XCM programs and executor
//! configurations.
//!
//! XCM programs are composed of Instructions, which reference Locations and Assets.
+5 -5
View File
@@ -30,7 +30,7 @@ pezsp-runtime = { workspace = true }
xcm = { workspace = true }
xcm-builder = { workspace = true }
xcm-executor = { workspace = true }
xcm-runtime-apis = { workspace = true }
xcm-runtime-pezapis = { workspace = true }
# marked optional, used in benchmarking
pezframe-benchmarking = { optional = true, workspace = true }
@@ -42,7 +42,7 @@ pezpallet-assets = { workspace = true, default-features = true }
pezkuwi-runtime-teyrchains = { workspace = true, default-features = true }
pezkuwi-teyrchain-primitives = { workspace = true, default-features = true }
pezsp-tracing = { workspace = true, default-features = true }
xcm-simulator = { workspace = true, default-features = true }
xcm-pez-simulator = { workspace = true, default-features = true }
[features]
default = ["std"]
@@ -61,7 +61,7 @@ std = [
"tracing/std",
"xcm-builder/std",
"xcm-executor/std",
"xcm-runtime-apis/std",
"xcm-runtime-pezapis/std",
"xcm/std",
]
runtime-benchmarks = [
@@ -76,8 +76,8 @@ runtime-benchmarks = [
"pezsp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
"xcm-executor/runtime-benchmarks",
"xcm-runtime-apis/runtime-benchmarks",
"xcm-simulator/runtime-benchmarks",
"xcm-runtime-pezapis/runtime-benchmarks",
"xcm-pez-simulator/runtime-benchmarks",
"xcm/runtime-benchmarks",
]
test-utils = ["std"]
@@ -36,7 +36,7 @@ scale-info = { workspace = true, default-features = true }
pezsp-io = { workspace = true, default-features = true }
pezsp-runtime = { workspace = true, default-features = true }
xcm-builder = { workspace = true, default-features = true }
xcm-simulator = { workspace = true, default-features = true }
xcm-pez-simulator = { workspace = true, default-features = true }
[features]
default = ["std"]
@@ -71,7 +71,7 @@ runtime-benchmarks = [
"pezsp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
"xcm-executor/runtime-benchmarks",
"xcm-simulator/runtime-benchmarks",
"xcm-pez-simulator/runtime-benchmarks",
"xcm/runtime-benchmarks",
]
try-runtime = [
@@ -40,7 +40,7 @@ use xcm_executor::{
traits::{Identity, JustTry},
XcmExecutor,
};
use xcm_simulator::helpers::derive_topic_id;
use xcm_pez_simulator::helpers::derive_topic_id;
use crate::XcmPrecompile;
+4 -4
View File
@@ -72,7 +72,7 @@ use xcm_executor::{
},
AssetsInHolding,
};
use xcm_runtime_apis::{
use xcm_runtime_pezapis::{
authorized_aliases::{Error as AuthorizedAliasersApiError, OriginAliaser},
dry_run::{CallDryRunEffects, Error as XcmDryRunApiError, XcmDryRunEffects},
fees::Error as XcmPaymentApiError,
@@ -3063,7 +3063,7 @@ impl<T: Config> Pallet<T> {
///
/// Returns not only the call result and events, but also the local XCM, if any,
/// and any XCMs forwarded to other locations.
/// Meant to be used in the `xcm_runtime_apis::dry_run::DryRunApi` runtime API.
/// Meant to be used in the `xcm_runtime_pezapis::dry_run::DryRunApi` runtime API.
pub fn dry_run_call<Runtime, Router, OriginCaller, RuntimeCall>(
origin: OriginCaller,
call: RuntimeCall,
@@ -3119,7 +3119,7 @@ impl<T: Config> Pallet<T> {
/// Dry-runs `xcm` with the given `origin_location`.
///
/// Returns execution result, events, and any forwarded XCMs to other locations.
/// Meant to be used in the `xcm_runtime_apis::dry_run::DryRunApi` runtime API.
/// Meant to be used in the `xcm_runtime_pezapis::dry_run::DryRunApi` runtime API.
pub fn dry_run_xcm<Router>(
origin_location: VersionedLocation,
xcm: VersionedXcm<<T as Config>::RuntimeCall>,
@@ -3326,7 +3326,7 @@ impl<T: Config> Pallet<T> {
let asset_id = versioned_asset_id.clone().try_into().map_err(|()| {
tracing::trace!(
target: "xcm::xcm_runtime_apis::query_delivery_fees",
target: "xcm::xcm_runtime_pezapis::query_delivery_fees",
"Failed to convert asset id: {versioned_asset_id:?}!"
);
XcmPaymentApiError::VersionedConversionFailed
+1 -1
View File
@@ -456,7 +456,7 @@ pub mod v1 {
}
/// When adding a new XCM version, we need to run this migration for `pezpallet_xcm` to ensure that all
/// previously stored data with subkey prefix `XCM_VERSION-1` (and below) are migrated to the
/// previously stored data with pez_subkey prefix `XCM_VERSION-1` (and below) are migrated to the
/// `XCM_VERSION`.
///
/// NOTE: This migration can be permanently added to the runtime migrations.
+1 -1
View File
@@ -45,7 +45,7 @@ use xcm_executor::{
traits::{Identity, JustTry},
XcmExecutor,
};
use xcm_simulator::helpers::derive_topic_id;
use xcm_pez_simulator::helpers::derive_topic_id;
use crate::{self as pezpallet_xcm, TestWeightInfo};
+1 -1
View File
@@ -46,7 +46,7 @@ use xcm_executor::{
traits::{Properties, QueryHandler, QueryResponseStatus, ShouldExecute},
XcmExecutor,
};
use xcm_simulator::fake_message_hash;
use xcm_pez_simulator::fake_message_hash;
const ALICE: AccountId = AccountId::new([0u8; 32]);
const BOB: AccountId = AccountId::new([1u8; 32]);
+2 -2
View File
@@ -1,5 +1,5 @@
[package]
name = "xcm-procedural"
name = "xcm-pez-procedural"
description = "Procedural macros for XCM"
authors.workspace = true
edition.workspace = true
@@ -8,7 +8,7 @@ version = "7.0.0"
publish = true
homepage.workspace = true
repository.workspace = true
documentation = "https://docs.rs/xcm-procedural"
documentation = "https://docs.rs/xcm-pez-procedural"
[lints]
workspace = true
@@ -17,7 +17,7 @@
//! Test the struct generated by the `NumVariants` derive macro.
use pezframe_support::traits::Get;
use xcm_procedural::NumVariants;
use xcm_pez_procedural::NumVariants;
#[allow(dead_code)]
#[derive(NumVariants)]
@@ -16,7 +16,7 @@
//! Test error when using a badly formatted attribute.
use xcm_procedural::Builder;
use xcm_pez_procedural::Builder;
struct Xcm<Call>(pub Vec<Instruction<Call>>);
@@ -16,7 +16,7 @@
//! Test error when there's no `UnpaidExecution` instruction.
use xcm_procedural::Builder;
use xcm_pez_procedural::Builder;
struct Xcm<Call>(pub Vec<Instruction<Call>>);
@@ -17,7 +17,7 @@
//! Test error when attaching the derive builder macro to something
//! other than the XCM `Instruction` enum.
use xcm_procedural::Builder;
use xcm_pez_procedural::Builder;
#[derive(Builder)]
struct SomeStruct;
+1 -1
View File
@@ -641,7 +641,7 @@ impl From<()> for Junctions {
}
}
xcm_procedural::impl_conversion_functions_for_junctions_v3!();
xcm_pez_procedural::impl_conversion_functions_for_junctions_v3!();
#[cfg(test)]
mod tests {
+2 -2
View File
@@ -466,8 +466,8 @@ impl XcmContext {
Decode,
DecodeWithMemTracking,
TypeInfo,
xcm_procedural::XcmWeightInfoTrait,
xcm_procedural::Builder,
xcm_pez_procedural::XcmWeightInfoTrait,
xcm_pez_procedural::Builder,
)]
#[derive_where(Clone, Eq, PartialEq, Debug)]
#[codec(encode_bound())]
+1 -1
View File
@@ -518,7 +518,7 @@ impl<Interior: Into<Junctions>> From<AncestorThen<Interior>> for MultiLocation {
}
}
xcm_procedural::impl_conversion_functions_for_multilocation_v3!();
xcm_pez_procedural::impl_conversion_functions_for_multilocation_v3!();
#[cfg(test)]
mod tests {
+1 -1
View File
@@ -596,7 +596,7 @@ impl From<()> for Junctions {
}
}
xcm_procedural::impl_conversion_functions_for_junctions_v4!();
xcm_pez_procedural::impl_conversion_functions_for_junctions_v4!();
#[cfg(test)]
mod tests {
+1 -1
View File
@@ -555,7 +555,7 @@ impl From<pezsp_runtime::AccountId32> for Location {
}
}
xcm_procedural::impl_conversion_functions_for_location_v4!();
xcm_pez_procedural::impl_conversion_functions_for_location_v4!();
#[cfg(test)]
mod tests {
+2 -2
View File
@@ -429,8 +429,8 @@ impl XcmContext {
Decode,
DecodeWithMemTracking,
TypeInfo,
xcm_procedural::XcmWeightInfoTrait,
xcm_procedural::Builder,
xcm_pez_procedural::XcmWeightInfoTrait,
xcm_pez_procedural::Builder,
)]
#[derive_where(Clone, Eq, PartialEq, Debug)]
#[codec(encode_bound())]
+1 -1
View File
@@ -596,7 +596,7 @@ impl From<()> for Junctions {
}
}
xcm_procedural::impl_conversion_functions_for_junctions_v5!();
xcm_pez_procedural::impl_conversion_functions_for_junctions_v5!();
#[cfg(test)]
mod tests {
+1 -1
View File
@@ -541,7 +541,7 @@ impl From<pezsp_runtime::AccountId32> for Location {
}
}
xcm_procedural::impl_conversion_functions_for_location_v5!();
xcm_pez_procedural::impl_conversion_functions_for_location_v5!();
#[cfg(test)]
mod tests {
+3 -3
View File
@@ -381,8 +381,8 @@ impl XcmContext {
Decode,
DecodeWithMemTracking,
TypeInfo,
xcm_procedural::XcmWeightInfoTrait,
xcm_procedural::Builder,
xcm_pez_procedural::XcmWeightInfoTrait,
xcm_pez_procedural::Builder,
)]
#[derive_where(Clone, Eq, PartialEq, Debug)]
#[codec(encode_bound())]
@@ -1150,7 +1150,7 @@ pub enum Instruction<Call> {
PartialEq,
Eq,
Clone,
xcm_procedural::NumVariants,
xcm_pez_procedural::NumVariants,
)]
pub enum Hint {
/// Set asset claimer for all the trapped assets during the execution.
+2 -2
View File
@@ -47,7 +47,7 @@ primitive-types = { features = [
"scale-info",
], workspace = true }
pezsp-tracing = { workspace = true, default-features = true }
xcm-simulator = { workspace = true, default-features = true }
xcm-pez-simulator = { workspace = true, default-features = true }
[features]
default = ["std"]
@@ -67,7 +67,7 @@ runtime-benchmarks = [
"pezsp-io/runtime-benchmarks",
"pezsp-runtime/runtime-benchmarks",
"xcm-executor/runtime-benchmarks",
"xcm-simulator/runtime-benchmarks",
"xcm-pez-simulator/runtime-benchmarks",
"xcm/runtime-benchmarks",
]
std = [
+1 -1
View File
@@ -49,7 +49,7 @@ pub use xcm_executor::{
},
AssetsInHolding, Config,
};
pub use xcm_simulator::helpers::derive_topic_id;
pub use xcm_pez_simulator::helpers::derive_topic_id;
#[derive(Debug)]
pub enum TestOrigin {
@@ -24,7 +24,7 @@ use pezframe_system::{EnsureRoot, EnsureSigned};
use pezkuwi_primitives::{AccountIndex, BlakeTwo256, Signature};
use pezsp_runtime::{generic, traits::MaybeEquivalence, AccountId32, BuildStorage};
use xcm_executor::{traits::ConvertLocation, XcmExecutor};
use xcm_simulator::ParaId;
use xcm_pez_simulator::ParaId;
pub type TxExtension = (
pezframe_system::AuthorizeCall<Test>,
+1 -1
View File
@@ -38,7 +38,7 @@ use xcm_builder::{
IsChildSystemTeyrchain, IsConcrete, MintLocation, RespectSuspension, SignedAccountId32AsNative,
SignedToAccountId32, SovereignSignedViaLocation, TakeWeightCredit,
};
use xcm_simulator::helpers::derive_topic_id;
use xcm_pez_simulator::helpers::derive_topic_id;
pub type AccountId = AccountId32;
pub type Balance = u128;
+1 -1
View File
@@ -24,7 +24,7 @@ use pezkuwi_teyrchain_primitives::primitives::Id as ParaId;
use pezsp_runtime::traits::AccountIdConversion;
use xcm::latest::{prelude::*, Error::UntrustedTeleportLocation};
use xcm_executor::XcmExecutor;
use xcm_simulator::fake_message_hash;
use xcm_pez_simulator::fake_message_hash;
pub const ALICE: AccountId = AccountId::new([0u8; 32]);
pub const PARA_ID: u32 = 2000;
@@ -1,12 +1,12 @@
[package]
name = "xcm-executor-integration-tests"
name = "xcm-pez-executor-integration-tests"
description = "Integration tests for the XCM Executor"
authors.workspace = true
edition.workspace = true
license.workspace = true
version = "1.0.0"
publish = false
documentation = "https://docs.rs/xcm-executor-integration-tests"
documentation = "https://docs.rs/xcm-pez-executor-integration-tests"
repository = { workspace = true }
homepage = { workspace = true }
+1 -1
View File
@@ -17,7 +17,7 @@
//! Unit tests for the XCM executor.
//!
//! These exclude any cross-chain functionality. For those, look at the
//! `xcm-emulator` based tests in the pezcumulus folder.
//! `xcm-pez-emulator` based tests in the pezcumulus folder.
//! These tests deal with internal state changes of the XCVM.
mod initiate_transfer;
@@ -1,5 +1,5 @@
[package]
name = "xcm-simulator"
name = "xcm-pez-simulator"
description = "Test kit to simulate cross-chain message passing and XCM execution"
version = "7.0.0"
authors.workspace = true
@@ -7,7 +7,7 @@ edition.workspace = true
license.workspace = true
homepage.workspace = true
repository.workspace = true
documentation = "https://docs.rs/xcm-simulator"
documentation = "https://docs.rs/xcm-pez-simulator"
[lints]
workspace = true
@@ -1,13 +1,13 @@
[package]
name = "xcm-simulator-example"
description = "Examples of xcm-simulator usage."
name = "xcm-pez-simulator-example"
description = "Examples of xcm-pez-simulator usage."
authors.workspace = true
edition.workspace = true
license.workspace = true
version = "7.0.0"
homepage.workspace = true
repository.workspace = true
documentation = "https://docs.rs/xcm-simulator-example"
documentation = "https://docs.rs/xcm-pez-simulator-example"
publish = false
[lints]
@@ -36,7 +36,7 @@ pezkuwi-teyrchain-primitives = { workspace = true, default-features = true }
xcm = { workspace = true, default-features = true }
xcm-builder = { workspace = true, default-features = true }
xcm-executor = { workspace = true, default-features = true }
xcm-simulator = { workspace = true, default-features = true }
xcm-pez-simulator = { workspace = true, default-features = true }
[dev-dependencies]
pezsp-tracing = { workspace = true }
@@ -56,6 +56,6 @@ runtime-benchmarks = [
"pezsp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
"xcm-executor/runtime-benchmarks",
"xcm-simulator/runtime-benchmarks",
"xcm-pez-simulator/runtime-benchmarks",
"xcm/runtime-benchmarks",
]
@@ -29,7 +29,7 @@ use pezsp_runtime::BuildStorage;
use pezsp_tracing;
use xcm::prelude::*;
use xcm_executor::traits::ConvertLocation;
use xcm_simulator::{decl_test_network, decl_test_relay_chain, decl_test_teyrchain, TestExt};
use xcm_pez_simulator::{decl_test_network, decl_test_relay_chain, decl_test_teyrchain, TestExt};
pub const ALICE: pezsp_runtime::AccountId32 = pezsp_runtime::AccountId32::new([1u8; 32]);
pub const INITIAL_BALANCE: u128 = 1_000_000_000;
@@ -19,7 +19,7 @@ use crate::*;
use codec::Encode;
use pezframe_support::{assert_ok, weights::Weight};
use xcm::latest::QueryResponseInfo;
use xcm_simulator::{mock_message_queue::ReceivedDmp, TestExt};
use xcm_pez_simulator::{mock_message_queue::ReceivedDmp, TestExt};
// Helper function for forming buy execution message
fn buy_execution<C>(fees: impl Into<Asset>) -> Instruction<C> {
@@ -36,7 +36,7 @@ use pezsp_runtime::{
use xcm::latest::prelude::*;
use xcm_builder::{EnsureXcmOrigin, SignedToAccountId32};
use xcm_executor::{traits::ConvertLocation, XcmExecutor};
use xcm_simulator::mock_message_queue;
use xcm_pez_simulator::mock_message_queue;
pub type AccountId = AccountId32;
pub type Balance = u128;
@@ -17,7 +17,7 @@
use crate::teyrchain::Runtime;
use pezframe_support::parameter_types;
use xcm::latest::prelude::*;
use xcm_simulator::mock_message_queue::TeyrchainId;
use xcm_pez_simulator::mock_message_queue::TeyrchainId;
parameter_types! {
pub KsmPerSecondPerByte: (AssetId, u128, u128) = (AssetId(Parent.into()), 1, 1);
@@ -1,12 +1,12 @@
[package]
name = "xcm-simulator-fuzzer"
description = "Examples of xcm-simulator usage."
name = "xcm-pez-simulator-fuzzer"
description = "Examples of xcm-pez-simulator usage."
version = "1.0.0"
authors.workspace = true
edition.workspace = true
license.workspace = true
publish = false
documentation = "https://docs.rs/xcm-simulator-fuzzer"
documentation = "https://docs.rs/xcm-pez-simulator-fuzzer"
repository = { workspace = true }
homepage = { workspace = true }
@@ -42,7 +42,7 @@ pezkuwi-teyrchain-primitives = { workspace = true, default-features = true }
xcm = { workspace = true, default-features = true }
xcm-builder = { workspace = true, default-features = true }
xcm-executor = { workspace = true, default-features = true }
xcm-simulator = { workspace = true, default-features = true }
xcm-pez-simulator = { workspace = true, default-features = true }
[features]
try-runtime = [
@@ -71,6 +71,6 @@ runtime-benchmarks = [
"pezsp-runtime/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
"xcm-executor/runtime-benchmarks",
"xcm-simulator/runtime-benchmarks",
"xcm-pez-simulator/runtime-benchmarks",
"xcm/runtime-benchmarks",
]
@@ -26,7 +26,7 @@ use codec::DecodeLimit;
use pezkuwi_core_primitives::AccountId;
use pezkuwi_teyrchain_primitives::primitives::Id as ParaId;
use pezsp_runtime::{traits::AccountIdConversion, BuildStorage};
use xcm_simulator::{decl_test_network, decl_test_relay_chain, decl_test_teyrchain, TestExt};
use xcm_pez_simulator::{decl_test_network, decl_test_relay_chain, decl_test_teyrchain, TestExt};
#[cfg(feature = "try-runtime")]
use pezframe_support::traits::{TryState, TryStateSelect::All};
@@ -473,7 +473,7 @@ pub mod helpers {
///
/// ```
/// use pezsp_runtime::testing::H256;
/// use xcm_simulator::helpers::TopicIdTracker;
/// use xcm_pez_simulator::helpers::TopicIdTracker;
///
/// // Dummy topic IDs
/// let topic_id = H256::repeat_byte(0x42);
@@ -1,12 +1,12 @@
[package]
name = "xcm-runtime-apis"
name = "xcm-runtime-pezapis"
version = "0.1.1"
authors.workspace = true
edition.workspace = true
license = "Apache-2.0"
repository.workspace = true
description = "XCM runtime APIs"
documentation = "https://docs.rs/xcm-runtime-apis"
documentation = "https://docs.rs/xcm-runtime-pezapis"
homepage = { workspace = true }
[package.metadata.docs.rs]
@@ -32,7 +32,7 @@ pezsp-io = { workspace = true }
pezsp-tracing = { workspace = true, default-features = true }
tracing = { workspace = true }
xcm-builder = { workspace = true }
xcm-simulator = { workspace = true, default-features = true }
xcm-pez-simulator = { workspace = true, default-features = true }
[features]
default = ["std"]
@@ -62,6 +62,6 @@ runtime-benchmarks = [
"pezsp-io/runtime-benchmarks",
"xcm-builder/runtime-benchmarks",
"xcm-executor/runtime-benchmarks",
"xcm-simulator/runtime-benchmarks",
"xcm-pez-simulator/runtime-benchmarks",
"xcm/runtime-benchmarks",
]
@@ -27,7 +27,7 @@ use pezframe_support::{
use mock::*;
use pezsp_api::ProvideRuntimeApi;
use xcm::prelude::*;
use xcm_runtime_apis::conversions::{
use xcm_runtime_pezapis::conversions::{
Error as LocationToAccountApiError, LocationToAccountApi, LocationToAccountHelper,
};
@@ -20,7 +20,7 @@ use pezframe_support::pezsp_runtime::testing::H256;
use pezframe_system::RawOrigin;
use pezsp_api::ProvideRuntimeApi;
use xcm::prelude::*;
use xcm_runtime_apis::{
use xcm_runtime_pezapis::{
dry_run::{CallDryRunEffects, DryRunApi},
fees::XcmPaymentApi,
};
@@ -31,7 +31,7 @@ use mock::{
ExistentialDeposit, HereLocation, OriginCaller, RuntimeCall, RuntimeEvent, TestClient,
ASSET_HUB_ASSETS_PALLET_INSTANCE, ASSET_HUB_PARA_ID, USDT_ID,
};
use xcm_simulator::fake_message_hash;
use xcm_pez_simulator::fake_message_hash;
// Scenario: User `1` in the local chain (id 2000) wants to transfer assets to account `[0u8; 32]`
// on "AssetHub". He wants to make sure he has enough for fees, so before he calls the
@@ -43,13 +43,13 @@ use xcm_executor::{
XcmExecutor,
};
use xcm_runtime_apis::{
use xcm_runtime_pezapis::{
conversions::{Error as LocationToAccountApiError, LocationToAccountApi},
dry_run::{CallDryRunEffects, DryRunApi, Error as XcmDryRunApiError, XcmDryRunEffects},
fees::{Error as XcmPaymentApiError, XcmPaymentApi},
trusted_query::{Error as TrustedQueryApiError, TrustedQueryApi},
};
use xcm_simulator::helpers::derive_topic_id;
use xcm_pez_simulator::helpers::derive_topic_id;
construct_runtime! {
pub enum TestRuntime {
@@ -24,7 +24,7 @@ use pezframe_support::pezsp_runtime::testing::H256;
use mock::*;
use pezsp_api::ProvideRuntimeApi;
use xcm::{prelude::*, v3};
use xcm_runtime_apis::trusted_query::{Error, TrustedQueryApi};
use xcm_runtime_pezapis::trusted_query::{Error, TrustedQueryApi};
#[test]
fn query_trusted_reserve() {