git.delta.rocks / unique-network / refs/commits / 23641e0cc8f7

difftreelog

refactor(preimage) switch governance feature to preimage

Fahrrader2023-02-21parent: #cec8ffa.patch.diff
in: master

12 files changed

modifiedpallets/maintenance/src/benchmarking.rsdiffbeforeafterboth
--- a/pallets/maintenance/src/benchmarking.rs
+++ b/pallets/maintenance/src/benchmarking.rs
@@ -23,30 +23,6 @@
 use codec::Encode;
 use sp_std::vec;
 
-#[cfg(not(feature = "governance"))]
-benchmarks! {
-	enable {
-	}: _(RawOrigin::Root)
-	verify {
-		ensure!(<Enabled<T>>::get(), "didn't enable the MM");
-	}
-
-	disable {
-		Maintenance::<T>::enable(RawOrigin::Root.into())?;
-	}: _(RawOrigin::Root)
-	verify {
-		ensure!(!<Enabled<T>>::get(), "didn't disable the MM");
-	}
-
-	execute_preimage {
-		let call_hash = RuntimeCall::<T>::set_storage { items: vec![] }.encode();
-		let hash = T::Preimages::note(call_hash.into())?;
-	}: _(RawOrigin::Root, hash)
-	verify {
-	}
-}
-
-#[cfg(feature = "governance")]
 benchmarks! {
 	enable {
 	}: _(RawOrigin::Root)
modifiedpallets/maintenance/src/lib.rsdiffbeforeafterboth
--- a/pallets/maintenance/src/lib.rs
+++ b/pallets/maintenance/src/lib.rs
@@ -25,10 +25,7 @@
 
 #[frame_support::pallet]
 pub mod pallet {
-	use frame_support::{
-		dispatch::*,
-		pallet_prelude::*,
-	};
+	use frame_support::{dispatch::*, pallet_prelude::*};
 	use frame_support::{
 		traits::{QueryPreimage, StorePreimage},
 	};
@@ -108,11 +105,11 @@
 		#[pallet::call_index(2)]
 		#[pallet::weight(<T as Config>::WeightInfo::execute_preimage())]
 		pub fn execute_preimage(_origin: OriginFor<T>, _hash: H256) -> DispatchResult {
-			#[cfg(feature = "governance")]
+			#[cfg(feature = "preimage")]
 			{
 				let origin = _origin;
 				let hash = _hash;
-				
+
 				ensure_root(origin)?;
 
 				let len = T::Preimages::len(&hash).ok_or(DispatchError::Unavailable)?;
@@ -128,7 +125,7 @@
 				result
 			}
 
-			#[cfg(not(feature = "governance"))]
+			#[cfg(not(feature = "preimage"))]
 			{
 				Err(DispatchError::Unavailable)
 			}
deletedruntime/common/config/pallets/governance.rsdiffbeforeafterboth
--- a/runtime/common/config/pallets/governance.rs
+++ /dev/null
@@ -1,34 +0,0 @@
-// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
-// This file is part of Unique Network.
-
-// Unique Network is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-
-// Unique Network is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
-
-use frame_support::parameter_types;
-use frame_system::EnsureRoot;
-use crate::{AccountId, Balance, Balances, Runtime, RuntimeEvent};
-use up_common::constants::*;
-
-parameter_types! {
-	pub PreimageBaseDeposit: Balance = 1000 * UNIQUE; // deposit(2, 64);
-	// pub PreimageByteDeposit: Balance = 1 * CENTIUNIQUE; // deposit(0, 1);
-}
-
-impl pallet_preimage::Config for Runtime {
-	type WeightInfo = pallet_preimage::weights::SubstrateWeight<Runtime>;
-	type RuntimeEvent = RuntimeEvent;
-	type Currency = Balances;
-	type ManagerOrigin = EnsureRoot<AccountId>;
-	type BaseDeposit = PreimageBaseDeposit;
-	type ByteDeposit = TransactionByteFee;
-}
modifiedruntime/common/config/pallets/mod.rsdiffbeforeafterboth
--- a/runtime/common/config/pallets/mod.rs
+++ b/runtime/common/config/pallets/mod.rs
@@ -47,8 +47,8 @@
 #[cfg(feature = "collator-selection")]
 pub mod collator_selection;
 
-#[cfg(feature = "governance")]
-pub mod governance;
+#[cfg(feature = "preimage")]
+pub mod preimage;
 
 parameter_types! {
 	pub TreasuryAccountId: AccountId = TreasuryModuleId::get().into_account_truncating();
@@ -128,9 +128,9 @@
 	type RuntimeEvent = RuntimeEvent;
 	type RuntimeOrigin = RuntimeOrigin;
 	type RuntimeCall = RuntimeCall;
-	#[cfg(feature = "governance")]
+	#[cfg(feature = "preimage")]
 	type Preimages = crate::Preimage;
-	#[cfg(not(feature = "governance"))]
+	#[cfg(not(feature = "preimage"))]
 	type Preimages = ();
 	type WeightInfo = pallet_maintenance::weights::SubstrateWeight<Self>;
 }
addedruntime/common/config/pallets/preimage.rsdiffbeforeafterboth
--- /dev/null
+++ b/runtime/common/config/pallets/preimage.rs
@@ -0,0 +1,34 @@
+// Copyright 2019-2022 Unique Network (Gibraltar) Ltd.
+// This file is part of Unique Network.
+
+// Unique Network is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+
+// Unique Network is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details.
+
+// You should have received a copy of the GNU General Public License
+// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.
+
+use frame_support::parameter_types;
+use frame_system::EnsureRoot;
+use crate::{AccountId, Balance, Balances, Runtime, RuntimeEvent};
+use up_common::constants::*;
+
+parameter_types! {
+	pub PreimageBaseDeposit: Balance = 1000 * UNIQUE; // deposit(2, 64);
+	// pub PreimageByteDeposit: Balance = 1 * CENTIUNIQUE; // deposit(0, 1);
+}
+
+impl pallet_preimage::Config for Runtime {
+	type WeightInfo = pallet_preimage::weights::SubstrateWeight<Runtime>;
+	type RuntimeEvent = RuntimeEvent;
+	type Currency = Balances;
+	type ManagerOrigin = EnsureRoot<AccountId>;
+	type BaseDeposit = PreimageBaseDeposit;
+	type ByteDeposit = TransactionByteFee;
+}
modifiedruntime/common/construct_runtime.rsdiffbeforeafterboth
--- a/runtime/common/construct_runtime.rs
+++ b/runtime/common/construct_runtime.rs
@@ -56,7 +56,7 @@
                 #[cfg(feature = "collator-selection")]
                 Identity: pallet_identity::{Pallet, Call, Storage, Event<T>} = 40,
 
-                #[cfg(feature = "governance")]
+                #[cfg(feature = "preimage")]
                 Preimage: pallet_preimage::{Pallet, Call, Storage, Event<T>} = 41,
 
                 // XCM helpers.
modifiedruntime/common/maintenance.rsdiffbeforeafterboth
--- a/runtime/common/maintenance.rs
+++ b/runtime/common/maintenance.rs
@@ -86,7 +86,7 @@
 				| RuntimeCall::Session(_)
 				| RuntimeCall::Identity(_) => Err(TransactionValidityError::Invalid(InvalidTransaction::Call)),
 
-				#[cfg(feature = "governance")]
+				#[cfg(feature = "preimage")]
 				RuntimeCall::Preimage(_) => Err(TransactionValidityError::Invalid(InvalidTransaction::Call)),
 
 				#[cfg(feature = "pallet-test-utils")]
modifiedruntime/common/runtime_apis.rsdiffbeforeafterboth
--- a/runtime/common/runtime_apis.rs
+++ b/runtime/common/runtime_apis.rs
@@ -565,7 +565,7 @@
                     #[cfg(feature = "collator-selection")]
                     list_benchmark!(list, extra, pallet_identity, Identity);
 
-                    #[cfg(feature = "governance")]
+                    #[cfg(feature = "preimage")]
                     list_benchmark!(list, extra, pallet_preimage, Preimage);
 
                     #[cfg(feature = "foreign-assets")]
@@ -632,7 +632,7 @@
                     #[cfg(feature = "collator-selection")]
                     add_benchmark!(params, batches, pallet_identity, Identity);
 
-                    #[cfg(feature = "governance")]
+                    #[cfg(feature = "preimage")]
                     add_benchmark!(params, batches, pallet_preimage, Preimage);
 
                     #[cfg(feature = "foreign-assets")]
modifiedruntime/opal/Cargo.tomldiffbeforeafterboth
--- a/runtime/opal/Cargo.toml
+++ b/runtime/opal/Cargo.toml
@@ -18,7 +18,7 @@
 [features]
 default = ['opal-runtime', 'std']
 limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']
-opal-runtime = ['app-promotion', 'collator-selection', 'foreign-assets', 'governance', 'pallet-test-utils', 'refungible']
+opal-runtime = ['app-promotion', 'collator-selection', 'foreign-assets', 'preimage', 'pallet-test-utils', 'refungible']
 pov-estimate = []
 runtime-benchmarks = [
 	'cumulus-pallet-parachain-system/runtime-benchmarks',
@@ -191,7 +191,7 @@
 app-promotion = []
 collator-selection = []
 foreign-assets = []
-governance = []
+preimage = []
 pallet-test-utils = []
 refungible = []
 scheduler = []
modifiedruntime/quartz/Cargo.tomldiffbeforeafterboth
--- a/runtime/quartz/Cargo.toml
+++ b/runtime/quartz/Cargo.toml
@@ -20,7 +20,7 @@
 default = ['quartz-runtime', 'std']
 limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']
 pov-estimate = []
-quartz-runtime = ['app-promotion', 'collator-selection', 'foreign-assets', 'governance', 'refungible']
+quartz-runtime = ['app-promotion', 'collator-selection', 'foreign-assets', 'preimage', 'refungible']
 runtime-benchmarks = [
 	'cumulus-pallet-parachain-system/runtime-benchmarks',
 	'frame-benchmarking',
@@ -184,7 +184,7 @@
 app-promotion = []
 collator-selection = []
 foreign-assets = []
-governance = []
+preimage = []
 refungible = []
 scheduler = []
 
modifiedruntime/unique/Cargo.tomldiffbeforeafterboth
before · runtime/unique/Cargo.toml
1################################################################################2# Package34[package]5authors = ['Unique Network <support@uniquenetwork.io>']6build = 'build.rs'7description = 'Unique Runtime'8edition = '2021'9homepage = 'https://unique.network'10license = 'GPLv3'11name = 'unique-runtime'12repository = 'https://github.com/UniqueNetwork/unique-chain'13version.workspace = true1415[package.metadata.docs.rs]16targets = ['x86_64-unknown-linux-gnu']1718[features]19default = ['std', 'unique-runtime']20limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']21pov-estimate = []22runtime-benchmarks = [23	'frame-benchmarking',24	'frame-support/runtime-benchmarks',25	'frame-system-benchmarking',26	'frame-system/runtime-benchmarks',27	'hex-literal',28	'pallet-app-promotion/runtime-benchmarks',29	'pallet-balances/runtime-benchmarks',30	'pallet-collator-selection/runtime-benchmarks',31	'pallet-common/runtime-benchmarks',32	'pallet-configuration/runtime-benchmarks',33	'pallet-ethereum/runtime-benchmarks',34	'pallet-evm-coder-substrate/runtime-benchmarks',35	'pallet-evm-migration/runtime-benchmarks',36	'pallet-foreign-assets/runtime-benchmarks',37	'pallet-fungible/runtime-benchmarks',38	'pallet-identity/runtime-benchmarks',39	'pallet-inflation/runtime-benchmarks',40	'pallet-maintenance/runtime-benchmarks',41	'pallet-nonfungible/runtime-benchmarks',42	"pallet-preimage/runtime-benchmarks",43	'pallet-refungible/runtime-benchmarks',44	'pallet-structure/runtime-benchmarks',45	'pallet-timestamp/runtime-benchmarks',46	'pallet-unique/runtime-benchmarks',47	'pallet-xcm/runtime-benchmarks',48	'sp-runtime/runtime-benchmarks',49	'up-data-structs/runtime-benchmarks',50	'xcm-builder/runtime-benchmarks',51]52std = [53	'codec/std',54	'cumulus-pallet-aura-ext/std',55	'cumulus-pallet-parachain-system/std',56	'cumulus-pallet-xcm/std',57	'cumulus-pallet-xcmp-queue/std',58	'cumulus-primitives-core/std',59	'cumulus-primitives-utility/std',60	'frame-executive/std',61	'frame-support/std',62	'frame-system-rpc-runtime-api/std',63	'frame-system/std',64	'frame-try-runtime/std',65	'pallet-aura/std',66	'pallet-balances/std',67	# 'pallet-contracts/std',68	# 'pallet-contracts-primitives/std',69	# 'pallet-contracts-rpc-runtime-api/std',70	# 'pallet-contract-helpers/std',71	"pallet-preimage/std",72	"pallet-authorship/std",73	"pallet-identity/std",74	"pallet-session/std",75	"sp-consensus-aura/std",76	'app-promotion-rpc/std',77	'evm-coder/std',78	'fp-evm-mapping/std',79	'fp-rpc/std',80	'fp-self-contained/std',81	'pallet-app-promotion/std',82	'pallet-base-fee/std',83	'pallet-charge-transaction/std',84	'pallet-collator-selection/std',85	'pallet-common/std',86	'pallet-configuration/std',87	'pallet-ethereum/std',88	'pallet-evm-coder-substrate/std',89	'pallet-evm-contract-helpers/std',90	'pallet-evm-migration/std',91	'pallet-evm-transaction-payment/std',92	'pallet-evm/std',93	'pallet-fungible/std',94	'pallet-inflation/std',95	'pallet-nonfungible/std',96	'pallet-randomness-collective-flip/std',97	'pallet-refungible/std',98	'pallet-structure/std',99	'pallet-sudo/std',100	'pallet-timestamp/std',101	'pallet-transaction-payment-rpc-runtime-api/std',102	'pallet-transaction-payment/std',103	'pallet-treasury/std',104	'pallet-unique/std',105	'parachain-info/std',106	'sp-api/std',107	'sp-block-builder/std',108	'sp-core/std',109	'sp-inherents/std',110	'sp-io/std',111	'sp-offchain/std',112	'sp-runtime/std',113	'sp-session/std',114	'sp-std/std',115	'sp-transaction-pool/std',116	'sp-version/std',117	'up-common/std',118	'up-data-structs/std',119	'up-pov-estimate-rpc/std',120	'up-rpc/std',121	'up-sponsorship/std',122	'xcm-builder/std',123	'xcm-executor/std',124	'xcm/std',125126	"orml-tokens/std",127	"orml-traits/std",128	"orml-vesting/std",129	"orml-xtokens/std",130	"pallet-foreign-assets/std",131	"pallet-maintenance/std",132]133stubgen = ["evm-coder/stubgen"]134try-runtime = [135	"pallet-authorship/try-runtime",136	"pallet-collator-selection/try-runtime",137	"pallet-identity/try-runtime",138	"pallet-session/try-runtime",139	"pallet-preimage/try-runtime",140	'cumulus-pallet-aura-ext/try-runtime',141	'cumulus-pallet-dmp-queue/try-runtime',142	'cumulus-pallet-parachain-system/try-runtime',143	'cumulus-pallet-xcm/try-runtime',144	'cumulus-pallet-xcmp-queue/try-runtime',145	'fp-self-contained/try-runtime',146	'frame-executive/try-runtime',147	'frame-support/try-runtime',148	'frame-system/try-runtime',149	'frame-try-runtime',150	'orml-tokens/try-runtime',151	'orml-vesting/try-runtime',152	'orml-xtokens/try-runtime',153	'pallet-app-promotion/try-runtime',154	'pallet-aura/try-runtime',155	'pallet-balances/try-runtime',156	'pallet-charge-transaction/try-runtime',157	'pallet-common/try-runtime',158	'pallet-configuration/try-runtime',159	'pallet-ethereum/try-runtime',160	'pallet-evm-coder-substrate/try-runtime',161	'pallet-evm-contract-helpers/try-runtime',162	'pallet-evm-migration/try-runtime',163	'pallet-evm-transaction-payment/try-runtime',164	'pallet-evm/try-runtime',165	'pallet-foreign-assets/try-runtime',166	'pallet-fungible/try-runtime',167	'pallet-inflation/try-runtime',168	'pallet-maintenance/try-runtime',169	'pallet-nonfungible/try-runtime',170	'pallet-randomness-collective-flip/try-runtime',171	'pallet-refungible/try-runtime',172	'pallet-structure/try-runtime',173	'pallet-sudo/try-runtime',174	'pallet-timestamp/try-runtime',175	'pallet-transaction-payment/try-runtime',176	'pallet-treasury/try-runtime',177	'pallet-unique/try-runtime',178	'pallet-xcm/try-runtime',179	'parachain-info/try-runtime',180]181unique-runtime = ['app-promotion', 'foreign-assets', 'refungible']182183app-promotion = []184collator-selection = []185foreign-assets = []186governance = []187refungible = []188scheduler = []189190################################################################################191# local dependencies192193[dependencies]194# Note: `package = "parity-scale-codec"` must be supplied since the `Encode` macro searches for it.195codec = { workspace = true, package = "parity-scale-codec" }196197cumulus-pallet-aura-ext = { workspace = true }198cumulus-pallet-dmp-queue = { workspace = true }199cumulus-pallet-parachain-system = { workspace = true }200cumulus-pallet-xcm = { workspace = true }201cumulus-pallet-xcmp-queue = { workspace = true }202cumulus-primitives-core = { workspace = true }203cumulus-primitives-timestamp = { workspace = true }204cumulus-primitives-utility = { workspace = true }205frame-executive = { workspace = true }206frame-support = { workspace = true }207frame-system = { workspace = true }208frame-system-rpc-runtime-api = { workspace = true }209orml-tokens = { workspace = true }210orml-traits = { workspace = true }211orml-vesting = { workspace = true }212orml-xtokens = { workspace = true }213pallet-aura = { workspace = true }214pallet-authorship = { workspace = true }215pallet-balances = { workspace = true }216pallet-preimage = { workspace = true }217pallet-randomness-collective-flip = { workspace = true }218pallet-session = { workspace = true }219pallet-sudo = { workspace = true }220pallet-timestamp = { workspace = true }221pallet-transaction-payment = { workspace = true }222pallet-transaction-payment-rpc-runtime-api = { workspace = true }223pallet-treasury = { workspace = true }224pallet-xcm = { workspace = true }225parachain-info = { workspace = true }226polkadot-parachain = { workspace = true }227smallvec = { workspace = true }228sp-api = { workspace = true }229sp-arithmetic = { workspace = true }230sp-block-builder = { workspace = true }231sp-consensus-aura = { workspace = true }232sp-core = { workspace = true }233sp-inherents = { workspace = true }234sp-io = { workspace = true }235sp-offchain = { workspace = true }236sp-runtime = { workspace = true }237sp-session = { workspace = true }238sp-std = { workspace = true }239sp-transaction-pool = { workspace = true }240sp-version = { workspace = true }241xcm = { workspace = true }242xcm-builder = { workspace = true }243xcm-executor = { workspace = true }244245app-promotion-rpc = { workspace = true }246derivative = { workspace = true }247log = { workspace = true }248pallet-app-promotion = { workspace = true }249pallet-collator-selection = { workspace = true }250pallet-common = { workspace = true }251pallet-configuration = { workspace = true }252pallet-fungible = { workspace = true }253pallet-identity = { workspace = true }254pallet-inflation = { workspace = true }255pallet-nonfungible = { workspace = true }256pallet-refungible = { workspace = true }257pallet-structure = { workspace = true }258pallet-unique = { workspace = true }259scale-info = { workspace = true }260up-common = { workspace = true }261up-data-structs = { workspace = true }262up-pov-estimate-rpc = { workspace = true }263up-rpc = { workspace = true }264# pallet-contract-helpers = { path = '../pallets/contract-helpers', default-features = false, version = '0.1.0' }265evm-coder = { workspace = true }266fp-evm = { workspace = true }267fp-evm-mapping = { workspace = true }268fp-rpc = { workspace = true }269fp-self-contained = { workspace = true }270num_enum = { workspace = true }271pallet-base-fee = { workspace = true }272pallet-charge-transaction = { workspace = true }273pallet-ethereum = { workspace = true }274pallet-evm = { workspace = true }275pallet-evm-coder-substrate = { workspace = true }276pallet-evm-contract-helpers = { workspace = true }277pallet-evm-migration = { workspace = true }278pallet-evm-precompile-simple = { workspace = true }279pallet-evm-transaction-payment = { workspace = true }280pallet-foreign-assets = { workspace = true }281pallet-maintenance = { workspace = true }282precompile-utils-macro = { workspace = true }283up-sponsorship = { workspace = true }284285################################################################################286# Optional dependencies287288frame-system-benchmarking = { workspace = true, optional = true }289frame-benchmarking = { workspace = true, optional = true }290frame-try-runtime = { workspace = true, optional = true }291serde = { workspace = true, optional = true }292hex-literal = { workspace = true, optional = true }293294################################################################################295# Test dependencies296297pallet-test-utils = { workspace = true }298299################################################################################300# Other Dependencies301302impl-trait-for-tuples = { workspace = true }303304[dev-dependencies]305logtest = { workspace = true }306307[build-dependencies]308substrate-wasm-builder = { workspace = true }
after · runtime/unique/Cargo.toml
1################################################################################2# Package34[package]5authors = ['Unique Network <support@uniquenetwork.io>']6build = 'build.rs'7description = 'Unique Runtime'8edition = '2021'9homepage = 'https://unique.network'10license = 'GPLv3'11name = 'unique-runtime'12repository = 'https://github.com/UniqueNetwork/unique-chain'13version.workspace = true1415[package.metadata.docs.rs]16targets = ['x86_64-unknown-linux-gnu']1718[features]19default = ['std', 'unique-runtime']20limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']21pov-estimate = []22runtime-benchmarks = [23	'frame-benchmarking',24	'frame-support/runtime-benchmarks',25	'frame-system-benchmarking',26	'frame-system/runtime-benchmarks',27	'hex-literal',28	'pallet-app-promotion/runtime-benchmarks',29	'pallet-balances/runtime-benchmarks',30	'pallet-collator-selection/runtime-benchmarks',31	'pallet-common/runtime-benchmarks',32	'pallet-configuration/runtime-benchmarks',33	'pallet-ethereum/runtime-benchmarks',34	'pallet-evm-coder-substrate/runtime-benchmarks',35	'pallet-evm-migration/runtime-benchmarks',36	'pallet-foreign-assets/runtime-benchmarks',37	'pallet-fungible/runtime-benchmarks',38	'pallet-identity/runtime-benchmarks',39	'pallet-inflation/runtime-benchmarks',40	'pallet-maintenance/runtime-benchmarks',41	'pallet-nonfungible/runtime-benchmarks',42	"pallet-preimage/runtime-benchmarks",43	'pallet-refungible/runtime-benchmarks',44	'pallet-structure/runtime-benchmarks',45	'pallet-timestamp/runtime-benchmarks',46	'pallet-unique/runtime-benchmarks',47	'pallet-xcm/runtime-benchmarks',48	'sp-runtime/runtime-benchmarks',49	'up-data-structs/runtime-benchmarks',50	'xcm-builder/runtime-benchmarks',51]52std = [53	'codec/std',54	'cumulus-pallet-aura-ext/std',55	'cumulus-pallet-parachain-system/std',56	'cumulus-pallet-xcm/std',57	'cumulus-pallet-xcmp-queue/std',58	'cumulus-primitives-core/std',59	'cumulus-primitives-utility/std',60	'frame-executive/std',61	'frame-support/std',62	'frame-system-rpc-runtime-api/std',63	'frame-system/std',64	'frame-try-runtime/std',65	'pallet-aura/std',66	'pallet-balances/std',67	# 'pallet-contracts/std',68	# 'pallet-contracts-primitives/std',69	# 'pallet-contracts-rpc-runtime-api/std',70	# 'pallet-contract-helpers/std',71	"pallet-preimage/std",72	"pallet-authorship/std",73	"pallet-identity/std",74	"pallet-session/std",75	"sp-consensus-aura/std",76	'app-promotion-rpc/std',77	'evm-coder/std',78	'fp-evm-mapping/std',79	'fp-rpc/std',80	'fp-self-contained/std',81	'pallet-app-promotion/std',82	'pallet-base-fee/std',83	'pallet-charge-transaction/std',84	'pallet-collator-selection/std',85	'pallet-common/std',86	'pallet-configuration/std',87	'pallet-ethereum/std',88	'pallet-evm-coder-substrate/std',89	'pallet-evm-contract-helpers/std',90	'pallet-evm-migration/std',91	'pallet-evm-transaction-payment/std',92	'pallet-evm/std',93	'pallet-fungible/std',94	'pallet-inflation/std',95	'pallet-nonfungible/std',96	'pallet-randomness-collective-flip/std',97	'pallet-refungible/std',98	'pallet-structure/std',99	'pallet-sudo/std',100	'pallet-timestamp/std',101	'pallet-transaction-payment-rpc-runtime-api/std',102	'pallet-transaction-payment/std',103	'pallet-treasury/std',104	'pallet-unique/std',105	'parachain-info/std',106	'sp-api/std',107	'sp-block-builder/std',108	'sp-core/std',109	'sp-inherents/std',110	'sp-io/std',111	'sp-offchain/std',112	'sp-runtime/std',113	'sp-session/std',114	'sp-std/std',115	'sp-transaction-pool/std',116	'sp-version/std',117	'up-common/std',118	'up-data-structs/std',119	'up-pov-estimate-rpc/std',120	'up-rpc/std',121	'up-sponsorship/std',122	'xcm-builder/std',123	'xcm-executor/std',124	'xcm/std',125126	"orml-tokens/std",127	"orml-traits/std",128	"orml-vesting/std",129	"orml-xtokens/std",130	"pallet-foreign-assets/std",131	"pallet-maintenance/std",132]133stubgen = ["evm-coder/stubgen"]134try-runtime = [135	"pallet-authorship/try-runtime",136	"pallet-collator-selection/try-runtime",137	"pallet-identity/try-runtime",138	"pallet-session/try-runtime",139	"pallet-preimage/try-runtime",140	'cumulus-pallet-aura-ext/try-runtime',141	'cumulus-pallet-dmp-queue/try-runtime',142	'cumulus-pallet-parachain-system/try-runtime',143	'cumulus-pallet-xcm/try-runtime',144	'cumulus-pallet-xcmp-queue/try-runtime',145	'fp-self-contained/try-runtime',146	'frame-executive/try-runtime',147	'frame-support/try-runtime',148	'frame-system/try-runtime',149	'frame-try-runtime',150	'orml-tokens/try-runtime',151	'orml-vesting/try-runtime',152	'orml-xtokens/try-runtime',153	'pallet-app-promotion/try-runtime',154	'pallet-aura/try-runtime',155	'pallet-balances/try-runtime',156	'pallet-charge-transaction/try-runtime',157	'pallet-common/try-runtime',158	'pallet-configuration/try-runtime',159	'pallet-ethereum/try-runtime',160	'pallet-evm-coder-substrate/try-runtime',161	'pallet-evm-contract-helpers/try-runtime',162	'pallet-evm-migration/try-runtime',163	'pallet-evm-transaction-payment/try-runtime',164	'pallet-evm/try-runtime',165	'pallet-foreign-assets/try-runtime',166	'pallet-fungible/try-runtime',167	'pallet-inflation/try-runtime',168	'pallet-maintenance/try-runtime',169	'pallet-nonfungible/try-runtime',170	'pallet-randomness-collective-flip/try-runtime',171	'pallet-refungible/try-runtime',172	'pallet-structure/try-runtime',173	'pallet-sudo/try-runtime',174	'pallet-timestamp/try-runtime',175	'pallet-transaction-payment/try-runtime',176	'pallet-treasury/try-runtime',177	'pallet-unique/try-runtime',178	'pallet-xcm/try-runtime',179	'parachain-info/try-runtime',180]181unique-runtime = ['app-promotion', 'foreign-assets', 'refungible']182183app-promotion = []184collator-selection = []185foreign-assets = []186preimage = []187refungible = []188scheduler = []189190################################################################################191# local dependencies192193[dependencies]194# Note: `package = "parity-scale-codec"` must be supplied since the `Encode` macro searches for it.195codec = { workspace = true, package = "parity-scale-codec" }196197cumulus-pallet-aura-ext = { workspace = true }198cumulus-pallet-dmp-queue = { workspace = true }199cumulus-pallet-parachain-system = { workspace = true }200cumulus-pallet-xcm = { workspace = true }201cumulus-pallet-xcmp-queue = { workspace = true }202cumulus-primitives-core = { workspace = true }203cumulus-primitives-timestamp = { workspace = true }204cumulus-primitives-utility = { workspace = true }205frame-executive = { workspace = true }206frame-support = { workspace = true }207frame-system = { workspace = true }208frame-system-rpc-runtime-api = { workspace = true }209orml-tokens = { workspace = true }210orml-traits = { workspace = true }211orml-vesting = { workspace = true }212orml-xtokens = { workspace = true }213pallet-aura = { workspace = true }214pallet-authorship = { workspace = true }215pallet-balances = { workspace = true }216pallet-preimage = { workspace = true }217pallet-randomness-collective-flip = { workspace = true }218pallet-session = { workspace = true }219pallet-sudo = { workspace = true }220pallet-timestamp = { workspace = true }221pallet-transaction-payment = { workspace = true }222pallet-transaction-payment-rpc-runtime-api = { workspace = true }223pallet-treasury = { workspace = true }224pallet-xcm = { workspace = true }225parachain-info = { workspace = true }226polkadot-parachain = { workspace = true }227smallvec = { workspace = true }228sp-api = { workspace = true }229sp-arithmetic = { workspace = true }230sp-block-builder = { workspace = true }231sp-consensus-aura = { workspace = true }232sp-core = { workspace = true }233sp-inherents = { workspace = true }234sp-io = { workspace = true }235sp-offchain = { workspace = true }236sp-runtime = { workspace = true }237sp-session = { workspace = true }238sp-std = { workspace = true }239sp-transaction-pool = { workspace = true }240sp-version = { workspace = true }241xcm = { workspace = true }242xcm-builder = { workspace = true }243xcm-executor = { workspace = true }244245app-promotion-rpc = { workspace = true }246derivative = { workspace = true }247log = { workspace = true }248pallet-app-promotion = { workspace = true }249pallet-collator-selection = { workspace = true }250pallet-common = { workspace = true }251pallet-configuration = { workspace = true }252pallet-fungible = { workspace = true }253pallet-identity = { workspace = true }254pallet-inflation = { workspace = true }255pallet-nonfungible = { workspace = true }256pallet-refungible = { workspace = true }257pallet-structure = { workspace = true }258pallet-unique = { workspace = true }259scale-info = { workspace = true }260up-common = { workspace = true }261up-data-structs = { workspace = true }262up-pov-estimate-rpc = { workspace = true }263up-rpc = { workspace = true }264# pallet-contract-helpers = { path = '../pallets/contract-helpers', default-features = false, version = '0.1.0' }265evm-coder = { workspace = true }266fp-evm = { workspace = true }267fp-evm-mapping = { workspace = true }268fp-rpc = { workspace = true }269fp-self-contained = { workspace = true }270num_enum = { workspace = true }271pallet-base-fee = { workspace = true }272pallet-charge-transaction = { workspace = true }273pallet-ethereum = { workspace = true }274pallet-evm = { workspace = true }275pallet-evm-coder-substrate = { workspace = true }276pallet-evm-contract-helpers = { workspace = true }277pallet-evm-migration = { workspace = true }278pallet-evm-precompile-simple = { workspace = true }279pallet-evm-transaction-payment = { workspace = true }280pallet-foreign-assets = { workspace = true }281pallet-maintenance = { workspace = true }282precompile-utils-macro = { workspace = true }283up-sponsorship = { workspace = true }284285################################################################################286# Optional dependencies287288frame-system-benchmarking = { workspace = true, optional = true }289frame-benchmarking = { workspace = true, optional = true }290frame-try-runtime = { workspace = true, optional = true }291serde = { workspace = true, optional = true }292hex-literal = { workspace = true, optional = true }293294################################################################################295# Test dependencies296297pallet-test-utils = { workspace = true }298299################################################################################300# Other Dependencies301302impl-trait-for-tuples = { workspace = true }303304[dev-dependencies]305logtest = { workspace = true }306307[build-dependencies]308substrate-wasm-builder = { workspace = true }
modifiedtests/src/pallet-presence.test.tsdiffbeforeafterboth
--- a/tests/src/pallet-presence.test.ts
+++ b/tests/src/pallet-presence.test.ts
@@ -66,7 +66,7 @@
       const foreignAssets = 'foreignassets';
       const appPromotion = 'apppromotion';
       const collatorSelection = ['authorship', 'session', 'collatorselection', 'identity'];
-      const governance = ['preimage'];
+      const preimage = ['preimage'];
       const testUtils = 'testutils';
 
       if (chain.eq('OPAL by UNIQUE')) {
@@ -76,7 +76,7 @@
           appPromotion,
           testUtils,
           ...collatorSelection,
-          ...governance,
+          ...preimage,
         );
       } else if (chain.eq('QUARTZ by UNIQUE') || chain.eq('SAPPHIRE by UNIQUE')) {
         requiredPallets.push(
@@ -84,7 +84,7 @@
           appPromotion,
           foreignAssets,
           ...collatorSelection,
-          ...governance,
+          ...preimage,
         );
       } else if (chain.eq('UNIQUE')) {
         // Insert Unique additional pallets here