Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix tests and compile issues #1152

Merged
merged 6 commits into from
Aug 25, 2023
Merged
Show file tree
Hide file tree
Changes from 3 commits
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
4 changes: 2 additions & 2 deletions polkadot/node/core/pvf/common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ sc-executor-wasmtime = { path = "../../../../../substrate/client/executor/wasmti
sp-core = { path = "../../../../../substrate/primitives/core" }
sp-externalities = { path = "../../../../../substrate/primitives/externalities" }
sp-io = { path = "../../../../../substrate/primitives/io" }
sp-tracing = { path = "../../../../../substrate/primitives/tracing", optional = true }
sp-tracing = { path = "../../../../../substrate/primitives/tracing" }

[target.'cfg(target_os = "linux")'.dependencies]
landlock = "0.2.0"
Expand All @@ -37,4 +37,4 @@ tempfile = "3.3.0"
[features]
# This feature is used to export test code to other crates without putting it in the production build.
# Also used for building the puppet worker.
test-utils = [ "sp-tracing" ]
test-utils = [ ]
8 changes: 5 additions & 3 deletions polkadot/node/core/pvf/common/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,11 @@ pub mod worker;

pub use cpu_time::ProcessTime;

// Used by `decl_worker_main!`.
#[cfg(feature = "test-utils")]
pub use sp_tracing;
/// DO NOT USE - internal for macros only.
#[doc(hidden)]
pub mod __private {
pub use sp_tracing::try_init_simple;
}

const LOG_TARGET: &str = "parachain::pvf-common";

Expand Down
2 changes: 1 addition & 1 deletion polkadot/node/core/pvf/common/src/worker/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ macro_rules! decl_worker_main {
}

fn main() {
$crate::sp_tracing::try_init_simple();
$crate::__private::try_init_simple();

let args = std::env::args().collect::<Vec<_>>();
if args.len() == 1 {
Expand Down
2 changes: 1 addition & 1 deletion polkadot/node/subsystem-test-helpers/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,7 @@ pub fn subsystem_test_harness<M, OverseerFactory, Overseer, TestFactory, Test>(

futures::executor::block_on(async move {
future::join(overseer, test)
.timeout(Duration::from_secs(5))
.timeout(Duration::from_secs(10))
.await
.expect("test timed out instead of completing")
});
Expand Down
Loading