From 3d93ce7578e4e1ebe969db19f4a4648ddee98744 Mon Sep 17 00:00:00 2001 From: Elina Date: Sun, 13 Oct 2024 22:31:19 +0800 Subject: [PATCH] AnyScope::test needs feature = test cfg + fmt --- packages/yew/src/html/component/scope.rs | 2 +- packages/yew/src/lib.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/yew/src/html/component/scope.rs b/packages/yew/src/html/component/scope.rs index 9253228fa2e..952978e944f 100644 --- a/packages/yew/src/html/component/scope.rs +++ b/packages/yew/src/html/component/scope.rs @@ -513,7 +513,7 @@ mod feat_csr { use crate::scheduler; impl AnyScope { - #[cfg(test)] + #[cfg(any(test, feature = "test"))] pub(crate) fn test() -> Self { Self { type_id: TypeId::of::<()>(), diff --git a/packages/yew/src/lib.rs b/packages/yew/src/lib.rs index 63d6a82c00b..44918b4f108 100644 --- a/packages/yew/src/lib.rs +++ b/packages/yew/src/lib.rs @@ -293,7 +293,7 @@ mod app_handle; #[cfg(feature = "csr")] mod renderer; -#[cfg(all(feature = "csr", any(test, feature="test")))] +#[cfg(all(feature = "csr", any(test, feature = "test")))] #[allow(missing_docs)] pub mod tests;