Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fixes
  • Loading branch information
gavofyork committed Mar 18, 2023
commit fcaed93651a28e15b7f280441e1333e22a9b6106
6 changes: 4 additions & 2 deletions parachains/runtimes/assets/statemine/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1143,7 +1143,8 @@ mod tests {
use pallet_balances::WeightInfo;
let block = RuntimeBlockWeights::get().max_block;
let base = RuntimeBlockWeights::get().get(DispatchClass::Normal).base_extrinsic;
let transfer = base + weights::pallet_balances::WeightInfo::<Runtime>::transfer();
let transfer =
base + weights::pallet_balances::WeightInfo::<Runtime>::transfer_allow_death();

let fit = block.checked_div_per_component(&transfer).unwrap_or_default();
assert!(fit >= 1000, "{} should be at least 1000", fit);
Expand All @@ -1154,7 +1155,8 @@ mod tests {
fn sane_transfer_fee() {
use pallet_balances::WeightInfo;
let base = RuntimeBlockWeights::get().get(DispatchClass::Normal).base_extrinsic;
let transfer = base + weights::pallet_balances::WeightInfo::<Runtime>::transfer();
let transfer =
base + weights::pallet_balances::WeightInfo::<Runtime>::transfer_allow_death();

let fee: Balance = fee::WeightToFee::weight_to_fee(&transfer);
assert!(fee <= CENTS, "{} MILLICENTS should be at most 1000", fee / MILLICENTS);
Expand Down