From 62f8a47835bb77c181ef6e6ab54e12661d23cb60 Mon Sep 17 00:00:00 2001 From: bgallois <benjamin@gallois.cc> Date: Tue, 30 May 2023 16:26:18 +0200 Subject: [PATCH] fix pallet-balance errors --- pallets/oneshot-account/src/mock.rs | 6 +++++- pallets/universal-dividend/src/mock.rs | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/pallets/oneshot-account/src/mock.rs b/pallets/oneshot-account/src/mock.rs index 2de611479..6c86de84d 100644 --- a/pallets/oneshot-account/src/mock.rs +++ b/pallets/oneshot-account/src/mock.rs @@ -18,7 +18,7 @@ use crate::{self as pallet_oneshot_account}; use frame_support::{parameter_types, traits::Everything, weights::IdentityFee}; use frame_system as system; use pallet_transaction_payment::CurrencyAdapter; -use sp_core::H256; +use sp_core::{ConstU32, H256}; use sp_runtime::{ testing::Header, traits::{BlakeTwo256, IdentityLookup}, @@ -91,6 +91,10 @@ impl pallet_balances::Config for Test { type MaxReserves = (); type ReserveIdentifier = [u8; 8]; type RuntimeEvent = RuntimeEvent; + type HoldIdentifier = (); + type FreezeIdentifier = (); + type MaxHolds = ConstU32<0>; + type MaxFreezes = ConstU32<0>; } impl pallet_transaction_payment::Config for Test { type RuntimeEvent = RuntimeEvent; diff --git a/pallets/universal-dividend/src/mock.rs b/pallets/universal-dividend/src/mock.rs index bb5a4b20d..017f3c507 100644 --- a/pallets/universal-dividend/src/mock.rs +++ b/pallets/universal-dividend/src/mock.rs @@ -21,7 +21,7 @@ use frame_support::{ traits::{Everything, OnFinalize, OnInitialize}, }; use frame_system as system; -use sp_core::H256; +use sp_core::{ConstU32, H256}; use sp_runtime::{ testing::Header, traits::{BlakeTwo256, IdentityLookup}, @@ -93,6 +93,10 @@ impl pallet_balances::Config for Test { type MaxReserves = (); type ReserveIdentifier = [u8; 8]; type RuntimeEvent = RuntimeEvent; + type HoldIdentifier = (); + type FreezeIdentifier = (); + type MaxHolds = ConstU32<0>; + type MaxFreezes = ConstU32<0>; } parameter_types! { -- GitLab