From d57f11e0df479d30f20cac9f2c30221eba9cf84f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?D=C3=A1niel=20Varga?= Date: Fri, 12 Aug 2022 14:19:46 +0200 Subject: [PATCH] Fix test example so it doesn't fail Comment says "Or simply test if a request matches (doesn't reject)" therefore I would expect for assert to test for success. Also this example (for sum) will always match. It's confusing the code example actually tests if it doesn't match. --- src/test.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/test.rs b/src/test.rs index a656aca43..3c67c34d8 100644 --- a/src/test.rs +++ b/src/test.rs @@ -48,7 +48,7 @@ //! //! // Or simply test if a request matches (doesn't reject). //! assert!( -//! !warp::test::request() +//! warp::test::request() //! .path("/1/-5") //! .matches(&filter) //! .await