Skip to content

Commit 994df7a

Browse files
paritytech-release-backport-bot[bot]ggwpezgithub-actions[bot]EgorPopelyaev
authored
[stable2412] Weight update for pallet scheduler (#8627)
Update scheduler weights for #8726 This was originally a backport of #7785 but is now re-purposed. --------- Signed-off-by: Oliver Tale-Yazdi <[email protected]> Co-authored-by: Oliver Tale-Yazdi <[email protected]> Co-authored-by: cmd[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Egor_P <[email protected]>
1 parent 0946088 commit 994df7a

File tree

3 files changed

+163
-144
lines changed

3 files changed

+163
-144
lines changed

prdoc/pr_8627.prdoc

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
title: '[stable2412] Weight update for pallet scheduler'
2+
doc:
3+
- audience: Runtime Dev
4+
description: |-
5+
Update pallet scheduler weights and add sanity check test.
6+
7+
crates:
8+
- name: pallet-scheduler
9+
bump: patch

substrate/frame/scheduler/src/tests.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3035,3 +3035,13 @@ fn unavailable_call_is_detected() {
30353035
assert!(!Preimage::is_requested(&hash));
30363036
});
30373037
}
3038+
3039+
#[test]
3040+
fn service_task_fetched_weight_sane() {
3041+
use crate::{WeightInfo, weights::SubstrateWeight};
3042+
3043+
let w = SubstrateWeight::<Test>::service_task_fetched(0);
3044+
assert!(w.proof_size() < 100 * 1024, "Proof size is less then 100 KiB");
3045+
let w = <() as WeightInfo>::service_task_fetched(0);
3046+
assert!(w.proof_size() < 100 * 1024, "Proof size is less then 100 KiB");
3047+
}

0 commit comments

Comments
 (0)