snapshot before rebranding

This commit is contained in:
2025-12-14 07:37:21 +03:00
parent 5520d491a5
commit 09735eb97a
1752 changed files with 58116 additions and 15986 deletions
@@ -44,7 +44,7 @@ use xcm::latest::prelude::*;
pub trait WithRemoteGrandpaChainHelper {
/// This chain runtime.
type Runtime: BasicTeyrchainRuntime
+ cumulus_pallet_xcmp_queue::Config
+ pezcumulus_pallet_xcmp_queue::Config
+ BridgeGrandpaConfig<Self::GPI, BridgedChain = BridgedChainOf<Self::Runtime, Self::MPI>>
+ BridgeMessagesConfig<
Self::MPI,
@@ -74,7 +74,7 @@ impl<Runtime, AllPalletsWithoutSystem, GPI, MPI, RPI> WithRemoteGrandpaChainHelp
for WithRemoteGrandpaChainHelperAdapter<Runtime, AllPalletsWithoutSystem, GPI, MPI, RPI>
where
Runtime: BasicTeyrchainRuntime
+ cumulus_pallet_xcmp_queue::Config
+ pezcumulus_pallet_xcmp_queue::Config
+ BridgeGrandpaConfig<GPI, BridgedChain = BridgedChainOf<Runtime, MPI>>
+ BridgeMessagesConfig<
MPI,
@@ -46,7 +46,7 @@ use xcm::latest::prelude::*;
pub trait WithRemoteTeyrchainHelper {
/// This chain runtime.
type Runtime: BasicTeyrchainRuntime
+ cumulus_pallet_xcmp_queue::Config
+ pezcumulus_pallet_xcmp_queue::Config
+ BridgeGrandpaConfig<Self::GPI>
+ BridgeTeyrchainsConfig<Self::PPI>
+ BridgeMessagesConfig<
@@ -79,7 +79,7 @@ impl<Runtime, AllPalletsWithoutSystem, GPI, PPI, MPI, RPI> WithRemoteTeyrchainHe
for WithRemoteTeyrchainHelperAdapter<Runtime, AllPalletsWithoutSystem, GPI, PPI, MPI, RPI>
where
Runtime: BasicTeyrchainRuntime
+ cumulus_pallet_xcmp_queue::Config
+ pezcumulus_pallet_xcmp_queue::Config
+ BridgeGrandpaConfig<GPI>
+ BridgeTeyrchainsConfig<PPI>
+ BridgeMessagesConfig<
@@ -231,7 +231,7 @@ pub(crate) fn initialize_bridge_grandpa_pallet<Runtime, GPI>(
init_data: bp_header_chain::InitializationData<BridgedHeader<Runtime, GPI>>,
) where
Runtime: BridgeGrandpaConfig<GPI>
+ cumulus_pallet_teyrchain_system::Config
+ pezcumulus_pallet_teyrchain_system::Config
+ pezpallet_timestamp::Config,
{
pezpallet_bridge_grandpa::Pallet::<Runtime, GPI>::initialize(
@@ -274,7 +274,7 @@ pub fn relayed_incoming_message_works<Runtime, AllPalletsWithoutSystem, MPI>(
bp_runtime::ChainId,
) -> CallsAndVerifiers<Runtime>,
) where
Runtime: BasicTeyrchainRuntime + cumulus_pallet_xcmp_queue::Config + BridgeMessagesConfig<MPI>,
Runtime: BasicTeyrchainRuntime + pezcumulus_pallet_xcmp_queue::Config + BridgeMessagesConfig<MPI>,
AllPalletsWithoutSystem:
OnInitialize<BlockNumberFor<Runtime>> + OnFinalize<BlockNumberFor<Runtime>>,
MPI: 'static,
@@ -307,7 +307,7 @@ pub fn relayed_incoming_message_works<Runtime, AllPalletsWithoutSystem, MPI>(
2,
AccountId::from(alice).into(),
);
mock_open_hrmp_channel::<Runtime, cumulus_pallet_teyrchain_system::Pallet<Runtime>>(
mock_open_hrmp_channel::<Runtime, pezcumulus_pallet_teyrchain_system::Pallet<Runtime>>(
runtime_para_id.into(),
sibling_teyrchain_id.into(),
included_head,
@@ -351,7 +351,7 @@ pub fn relayed_incoming_message_works<Runtime, AllPalletsWithoutSystem, MPI>(
// verify that imported XCM contains original message
let imported_xcm =
RuntimeHelper::<cumulus_pallet_xcmp_queue::Pallet<Runtime>>::take_xcm(
RuntimeHelper::<pezcumulus_pallet_xcmp_queue::Pallet<Runtime>>::take_xcm(
sibling_teyrchain_id.into(),
)
.unwrap();
@@ -473,7 +473,7 @@ pub(crate) mod for_pallet_xcm_bridge_hub {
) where
Runtime: pezframe_system::Config
+ pezpallet_xcm_bridge_hub::Config<XcmOverBridgePalletInstance>
+ cumulus_pallet_teyrchain_system::Config
+ pezcumulus_pallet_teyrchain_system::Config
+ pezpallet_xcm::Config,
XcmOverBridgePalletInstance: 'static,
<Runtime as pezframe_system::Config>::RuntimeCall:
@@ -432,16 +432,16 @@ pub fn message_dispatch_routing_works<
slot_durations: SlotDurations,
runtime_para_id: u32,
sibling_teyrchain_id: u32,
unwrap_cumulus_pallet_teyrchain_system_event: Box<
dyn Fn(Vec<u8>) -> Option<cumulus_pallet_teyrchain_system::Event<Runtime>>,
unwrap_pezcumulus_pallet_teyrchain_system_event: Box<
dyn Fn(Vec<u8>) -> Option<pezcumulus_pallet_teyrchain_system::Event<Runtime>>,
>,
unwrap_cumulus_pallet_xcmp_queue_event: Box<
dyn Fn(Vec<u8>) -> Option<cumulus_pallet_xcmp_queue::Event<Runtime>>,
unwrap_pezcumulus_pallet_xcmp_queue_event: Box<
dyn Fn(Vec<u8>) -> Option<pezcumulus_pallet_xcmp_queue::Event<Runtime>>,
>,
prepare_configuration: impl Fn(),
) where
Runtime: BasicTeyrchainRuntime
+ cumulus_pallet_xcmp_queue::Config
+ pezcumulus_pallet_xcmp_queue::Config
+ BridgeMessagesConfig<MessagesPalletInstance, InboundPayload = test_data::XcmAsPlainPayload>,
AllPalletsWithoutSystem:
OnInitialize<BlockNumberFor<Runtime>> + OnFinalize<BlockNumberFor<Runtime>>,
@@ -450,7 +450,7 @@ pub fn message_dispatch_routing_works<
XcmConfig: xcm_executor::Config,
MessagesPalletInstance: 'static,
HrmpChannelOpener: pezframe_support::inherent::ProvideInherent<
Call = cumulus_pallet_teyrchain_system::Call<Runtime>,
Call = pezcumulus_pallet_teyrchain_system::Call<Runtime>,
>,
RuntimeNetwork: Get<NetworkId>,
BridgedNetwork: Get<NetworkId>,
@@ -501,10 +501,10 @@ pub fn message_dispatch_routing_works<
// check events - UpwardMessageSent
let mut events = <pezframe_system::Pallet<Runtime>>::events()
.into_iter()
.filter_map(|e| unwrap_cumulus_pallet_teyrchain_system_event(e.event.encode()));
.filter_map(|e| unwrap_pezcumulus_pallet_teyrchain_system_event(e.event.encode()));
assert!(events.any(|e| matches!(
e,
cumulus_pallet_teyrchain_system::Event::UpwardMessageSent { .. }
pezcumulus_pallet_teyrchain_system::Event::UpwardMessageSent { .. }
)));
// 2. this message is sent from other global consensus with destination of this Runtime
@@ -536,7 +536,7 @@ pub fn message_dispatch_routing_works<
assert_eq!(
<pezframe_system::Pallet<Runtime>>::events()
.into_iter()
.filter_map(|e| unwrap_cumulus_pallet_xcmp_queue_event(e.event.encode()))
.filter_map(|e| unwrap_pezcumulus_pallet_xcmp_queue_event(e.event.encode()))
.count(),
0
);
@@ -564,9 +564,9 @@ pub fn message_dispatch_routing_works<
// check events - XcmpMessageSent
let mut events = <pezframe_system::Pallet<Runtime>>::events()
.into_iter()
.filter_map(|e| unwrap_cumulus_pallet_xcmp_queue_event(e.event.encode()));
.filter_map(|e| unwrap_pezcumulus_pallet_xcmp_queue_event(e.event.encode()));
assert!(
events.any(|e| matches!(e, cumulus_pallet_xcmp_queue::Event::XcmpMessageSent { .. }))
events.any(|e| matches!(e, pezcumulus_pallet_xcmp_queue::Event::XcmpMessageSent { .. }))
);
})
}