From 88fb2befa0ff6244a891bcc14f46f1875dac6bc0 Mon Sep 17 00:00:00 2001 From: Svyatoslav Nikolsky Date: Mon, 27 Mar 2023 11:20:32 +0300 Subject: [PATCH] Rust cargo doc for all features (#1995) * run rustfix rustdoc in grandpa pallet benchmarks * enable rustdoc for all features * fix rialto parachain runtime compilation --- bridges/bin/rialto-parachain/runtime/Cargo.toml | 4 +++- bridges/bin/rialto/node/Cargo.toml | 1 + bridges/modules/grandpa/src/benchmarking.rs | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/bridges/bin/rialto-parachain/runtime/Cargo.toml b/bridges/bin/rialto-parachain/runtime/Cargo.toml index ed193b4e68..0018c8f390 100644 --- a/bridges/bin/rialto-parachain/runtime/Cargo.toml +++ b/bridges/bin/rialto-parachain/runtime/Cargo.toml @@ -83,10 +83,12 @@ runtime-benchmarks = [ 'sp-runtime/runtime-benchmarks', 'frame-benchmarking', 'frame-support/runtime-benchmarks', - 'frame-system-benchmarking', + 'frame-system-benchmarking/runtime-benchmarks', 'frame-system/runtime-benchmarks', 'pallet-balances/runtime-benchmarks', 'pallet-timestamp/runtime-benchmarks', + 'pallet-xcm/runtime-benchmarks', + 'xcm-builder/runtime-benchmarks', ] std = [ "bp-messages/std", diff --git a/bridges/bin/rialto/node/Cargo.toml b/bridges/bin/rialto/node/Cargo.toml index 859a62f22a..bc8841c4f8 100644 --- a/bridges/bin/rialto/node/Cargo.toml +++ b/bridges/bin/rialto/node/Cargo.toml @@ -45,5 +45,6 @@ frame-benchmarking-cli = { git = "https://github.com/paritytech/substrate", bran [features] default = [] runtime-benchmarks = [ + "polkadot-service/runtime-benchmarks", "rialto-runtime/runtime-benchmarks", ] diff --git a/bridges/modules/grandpa/src/benchmarking.rs b/bridges/modules/grandpa/src/benchmarking.rs index 5b9faea2a9..78c7fc362a 100644 --- a/bridges/modules/grandpa/src/benchmarking.rs +++ b/bridges/modules/grandpa/src/benchmarking.rs @@ -30,8 +30,8 @@ //! //! Consider the following: //! -//! / [B'] <- [C'] -//! [A] <- [B] <- [C] +//! / B <- C' +//! A <- B <- C //! //! The common ancestor of both forks is block A, so this is what GRANDPA will finalize. In order to //! verify this we will have vote ancestries of `[B, C, B', C']` and pre-commits `[C, C']`.