thread_local!(static TIMESTAMP: std::cell::RefCell<u64> = const { std::cell::RefCell::new(0) });
/// Check the parachain assignment using the orchestrator chain client, and send a `CcSpawnMsg` to
/// Checks the assignment for the next block, so if there is a session change on block 15, this will
// Save callback for later, used when collator rotates from container chain back to orchestrator chain
// collate_on_tanssi will not be called in solochains because solochains use a different consensus
panic!("Called collate_on_tanssi on solochain collator. This is unsupported and the runtime shouldn't allow this, it is a bug")
let relay_slot = sp_consensus_aura::inherents::InherentDataProvider::from_timestamp_and_slot_duration(
let randomness_enabler_messages: Vec<(bool, Option<[u8; 32]>)> = mock_randomness_receiver.drain().collect();
.expect("Should be able to query aux storage; qed").unwrap_or((false, Option::<[u8; 32]>::None).encode());
let (_mock_additional_randomness, mut mock_randomness_seed): (bool, Option<[u8; 32]>) = Decode::decode(&mut value.as_slice()).expect("Boolean non-decodable");
&[(RANDOMNESS_ACTIVATED_AUX_KEY, (enable_randomness, mock_randomness_seed).encode().as_slice())],
.expect("Should be able to query aux storage; qed").unwrap_or((false, Option::<[u8; 32]>::None).encode());
let (mock_additional_randomness, mock_randomness_seed): (bool, Option<[u8; 32]>) = Decode::decode(&mut value.as_slice()).expect("Boolean non-decodable");
let container_chains_exclusion_messages: Vec<Vec<ParaId>> = mock_container_chains_exclusion_receiver.drain().collect();
if let Some(mock_excluded_container_chains) = container_chains_exclusion_messages.last() {
.expect("Should be able to query aux storage; qed").unwrap_or(Vec::<ParaId>::new().encode());
let mock_excluded_container_chains: Vec<ParaId> = Decode::decode(&mut new_excluded_container_chains_value.as_slice()).expect("Vector non-decodable");
// This will allow any signed origin to deregister chains 2000 and 2001, and register 2002.
let (registrar_paras_key_2002, para_info_2002) = mocked_relay_keys::get_mocked_registrar_paras(2002.into());
additional_keys.extend([(para_head_key, para_head_data), (relay_slot_key, Slot::from(relay_slot).encode()), (registrar_paras_key_2002, para_info_2002)]);
additional_keys.extend([(RelayWellKnownKeys::CURRENT_BLOCK_RANDOMNESS.to_vec(), Some(mock_randomness).encode())]);
/// a [`RelayChainInProcessInterface`] to access relay chain data necessary for parachain operation.
/// the builder gets access to this concrete instance and instantiates a [`RelayChainInProcessInterface`] with it.
/// a [`RelayChainInProcessInterface`] to access relay chain data necessary for parachain operation.
/// the builder gets access to this concrete instance and instantiates a [`RelayChainInProcessInterface`] with it.
/// Provides an implementation of the [`RelayChainInterface`] using a local in-process relay chain node.
/// Provides an implementation of the [`RelayChainInterface`] using a local in-process relay chain node.