From fe5f6dd6aba69af7aeb9c0f36baab7683d88ed63 Mon Sep 17 00:00:00 2001 From: chungquantin <56880684+chungquantin@users.noreply.github.com> Date: Fri, 24 Jan 2025 14:40:28 +0700 Subject: [PATCH] refactor: reuse in nonfungibles pallet test --- pallets/api/src/fungibles/tests.rs | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/pallets/api/src/fungibles/tests.rs b/pallets/api/src/fungibles/tests.rs index 364ae31fe..43881ac0a 100644 --- a/pallets/api/src/fungibles/tests.rs +++ b/pallets/api/src/fungibles/tests.rs @@ -670,7 +670,6 @@ mod read_weights { use frame_support::weights::Weight; use super::*; - use crate::fungibles::{weights::WeightInfo, Config}; struct ReadWeightInfo { total_supply: Weight, @@ -712,13 +711,13 @@ mod read_weights { token_exists, } = ReadWeightInfo::new(); - assert_eq!(total_supply, ::WeightInfo::total_supply()); - assert_eq!(balance_of, ::WeightInfo::balance_of()); - assert_eq!(allowance, ::WeightInfo::allowance()); - assert_eq!(token_name, ::WeightInfo::token_name()); - assert_eq!(token_symbol, ::WeightInfo::token_symbol()); - assert_eq!(token_decimals, ::WeightInfo::token_decimals()); - assert_eq!(token_exists, ::WeightInfo::token_exists()); + assert_eq!(total_supply, WeightInfo::total_supply()); + assert_eq!(balance_of, WeightInfo::balance_of()); + assert_eq!(allowance, WeightInfo::allowance()); + assert_eq!(token_name, WeightInfo::token_name()); + assert_eq!(token_symbol, WeightInfo::token_symbol()); + assert_eq!(token_decimals, WeightInfo::token_decimals()); + assert_eq!(token_exists, WeightInfo::token_exists()); } // These types read from the `AssetMetadata` storage.