mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-14 16:51:03 +00:00
Remove Ord impl for Weights V2 and add comparison fns (#12183)
* Remove Ord impl for Weights V2 and add comparison fns * Remove TODO * Update frame/multisig/src/lib.rs Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * Update frame/election-provider-multi-phase/src/unsigned.rs Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * Remove unused import * cargo fmt * Fix tests * Fix more tests * cargo fmt * Fix more tests * Update frame/contracts/src/wasm/mod.rs Co-authored-by: Alexander Theißen <alex.theissen@me.com> * Update weight benchmarking templates Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> Co-authored-by: Alexander Theißen <alex.theissen@me.com>
This commit is contained in:
@@ -985,7 +985,7 @@ pub mod pallet {
|
||||
let size = Self::snapshot_metadata().ok_or(Error::<T>::MissingSnapshotMetadata)?;
|
||||
|
||||
ensure!(
|
||||
Self::solution_weight_of(&raw_solution, size) < T::SignedMaxWeight::get(),
|
||||
Self::solution_weight_of(&raw_solution, size).all_lt(T::SignedMaxWeight::get()),
|
||||
Error::<T>::SignedTooMuchWeight,
|
||||
);
|
||||
|
||||
@@ -2299,8 +2299,8 @@ mod tests {
|
||||
};
|
||||
|
||||
let mut active = 1;
|
||||
while weight_with(active) <=
|
||||
<Runtime as frame_system::Config>::BlockWeights::get().max_block ||
|
||||
while weight_with(active)
|
||||
.all_lte(<Runtime as frame_system::Config>::BlockWeights::get().max_block) ||
|
||||
active == all_voters
|
||||
{
|
||||
active += 1;
|
||||
|
||||
Reference in New Issue
Block a user