From 36fe6ff32a8554bd0f2455299a75bad9d2b6befa Mon Sep 17 00:00:00 2001 From: michele Date: Sun, 19 Jun 2022 21:45:35 +0200 Subject: [PATCH] #148 Documentation --- README.md | 3 +++ rstest/src/lib.rs | 8 ++++++++ rstest_macros/src/lib.rs | 3 +++ 3 files changed, 14 insertions(+) diff --git a/README.md b/README.md index d62de38..bfde5e7 100644 --- a/README.md +++ b/README.md @@ -226,6 +226,9 @@ async fn group_one_timeout_override(#[case] delay: Duration, #[case] expected: u } ``` +If you want to use `timeout` for `async` test you need to use `async-timeout` +feature (enabled by default). + ### Inject Test Attribute If you would like to use another `test` attribute for your test you can simply diff --git a/rstest/src/lib.rs b/rstest/src/lib.rs index e11e300..adf9e65 100644 --- a/rstest/src/lib.rs +++ b/rstest/src/lib.rs @@ -226,6 +226,14 @@ //! } //! ``` //! You can use this feature also in value list and in fixture default value. +//! +//! # Optional features +//! +//! `rstest` Enable all fetures by default. You can disable them if you need to +//! speed up compilation. +//! +//! - **`async-timeout`** *(enabled by default)* — Implement timeout for async +//! tests. #[doc(hidden)] pub mod magic_conversion; diff --git a/rstest_macros/src/lib.rs b/rstest_macros/src/lib.rs index 46818a2..cc9f67b 100644 --- a/rstest_macros/src/lib.rs +++ b/rstest_macros/src/lib.rs @@ -782,6 +782,9 @@ pub fn fixture( /// } /// ``` /// +/// If you want to use `timeout` for `async` test you need to use `async-timeout` +/// feature (enabled by default). +/// /// ## Inject Test Attribute /// /// If you would like to use another `test` attribute for your test you can simply