From 7b2aeaa0295ae3bce68996b28b12a1bab6092f40 Mon Sep 17 00:00:00 2001 From: Krayt78 Date: Tue, 17 Dec 2024 21:45:35 +0100 Subject: [PATCH 1/4] changed toml and deps --- Cargo.lock | 3 +-- substrate/frame/paged-list/fuzzer/Cargo.toml | 3 +-- substrate/frame/paged-list/fuzzer/src/paged_list.rs | 4 +--- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 02d7da8f7657..c60ff0435263 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -14346,10 +14346,9 @@ name = "pallet-paged-list-fuzzer" version = "0.1.0" dependencies = [ "arbitrary", - "frame-support 28.0.0", "honggfuzz", "pallet-paged-list 0.6.0", - "sp-io 30.0.0", + "polkadot-sdk-frame 0.1.0", ] [[package]] diff --git a/substrate/frame/paged-list/fuzzer/Cargo.toml b/substrate/frame/paged-list/fuzzer/Cargo.toml index d0108254ed2d..7509010fbdc3 100644 --- a/substrate/frame/paged-list/fuzzer/Cargo.toml +++ b/substrate/frame/paged-list/fuzzer/Cargo.toml @@ -20,6 +20,5 @@ path = "src/paged_list.rs" arbitrary = { workspace = true } honggfuzz = { workspace = true } -frame-support = { features = ["std"], workspace = true } -sp-io = { features = ["std"], workspace = true } +frame = { workspace = true, features = ["experimental", "runtime"] } pallet-paged-list = { features = ["std"], workspace = true } diff --git a/substrate/frame/paged-list/fuzzer/src/paged_list.rs b/substrate/frame/paged-list/fuzzer/src/paged_list.rs index 43b797eee6bf..5ac73e18deb8 100644 --- a/substrate/frame/paged-list/fuzzer/src/paged_list.rs +++ b/substrate/frame/paged-list/fuzzer/src/paged_list.rs @@ -29,10 +29,8 @@ use arbitrary::Arbitrary; use honggfuzz::fuzz; - -use frame_support::{storage::StorageList, StorageNoopGuard}; +use frame::prelude::*; use pallet_paged_list::mock::{PagedList as List, *}; -use sp_io::TestExternalities; type Meta = MetaOf; fn main() { From f9d4a637a7c173bce22567b4c370f8f0a4fe0f56 Mon Sep 17 00:00:00 2001 From: Krayt78 Date: Wed, 18 Dec 2024 10:04:19 +0100 Subject: [PATCH 2/4] fix + fmt --- substrate/frame/paged-list/fuzzer/Cargo.toml | 7 ++++++- substrate/frame/paged-list/fuzzer/src/paged_list.rs | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/substrate/frame/paged-list/fuzzer/Cargo.toml b/substrate/frame/paged-list/fuzzer/Cargo.toml index 7509010fbdc3..369579199cfb 100644 --- a/substrate/frame/paged-list/fuzzer/Cargo.toml +++ b/substrate/frame/paged-list/fuzzer/Cargo.toml @@ -19,6 +19,11 @@ path = "src/paged_list.rs" [dependencies] arbitrary = { workspace = true } honggfuzz = { workspace = true } - frame = { workspace = true, features = ["experimental", "runtime"] } pallet-paged-list = { features = ["std"], workspace = true } + +[features] +default = ["std"] +std = [ + "frame/std", +] diff --git a/substrate/frame/paged-list/fuzzer/src/paged_list.rs b/substrate/frame/paged-list/fuzzer/src/paged_list.rs index 5ac73e18deb8..f0f914de1422 100644 --- a/substrate/frame/paged-list/fuzzer/src/paged_list.rs +++ b/substrate/frame/paged-list/fuzzer/src/paged_list.rs @@ -29,7 +29,12 @@ use arbitrary::Arbitrary; use honggfuzz::fuzz; -use frame::prelude::*; + +use frame::{ + prelude::*, runtime::prelude::storage::storage_noop_guard::StorageNoopGuard, + testing_prelude::TestExternalities, +}; + use pallet_paged_list::mock::{PagedList as List, *}; type Meta = MetaOf; From 9353d7c9a48a28020a870319cf25584aedaaa695 Mon Sep 17 00:00:00 2001 From: Krayt78 Date: Sat, 21 Dec 2024 15:24:51 +0100 Subject: [PATCH 3/4] fix toml --- substrate/frame/paged-list/fuzzer/Cargo.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/substrate/frame/paged-list/fuzzer/Cargo.toml b/substrate/frame/paged-list/fuzzer/Cargo.toml index a4b06b4150d7..006d7e71c9f8 100644 --- a/substrate/frame/paged-list/fuzzer/Cargo.toml +++ b/substrate/frame/paged-list/fuzzer/Cargo.toml @@ -18,12 +18,12 @@ path = "src/paged_list.rs" [dependencies] arbitrary = { workspace = true } -honggfuzz = { workspace = true } frame = { workspace = true, features = ["experimental", "runtime"] } +honggfuzz = { workspace = true } pallet-paged-list = { features = ["std"], workspace = true } [features] default = ["std"] std = [ "frame/std", -] \ No newline at end of file +] From 6ad36142012a703eb465f7f167ee33410a071cb2 Mon Sep 17 00:00:00 2001 From: Krayt78 Date: Sat, 21 Dec 2024 16:44:43 +0100 Subject: [PATCH 4/4] updated toml --- substrate/frame/paged-list/fuzzer/Cargo.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/substrate/frame/paged-list/fuzzer/Cargo.toml b/substrate/frame/paged-list/fuzzer/Cargo.toml index 006d7e71c9f8..e00f55daf8a1 100644 --- a/substrate/frame/paged-list/fuzzer/Cargo.toml +++ b/substrate/frame/paged-list/fuzzer/Cargo.toml @@ -26,4 +26,5 @@ pallet-paged-list = { features = ["std"], workspace = true } default = ["std"] std = [ "frame/std", + "pallet-paged-list/std", ]