From d2a0a73a3627904868528546ac27ae415e0a545a Mon Sep 17 00:00:00 2001 From: Miles Liu Date: Tue, 21 Mar 2023 09:18:37 +0800 Subject: [PATCH] touch: fix `err_expect` clippy error --- src/uu/touch/src/touch.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/uu/touch/src/touch.rs b/src/uu/touch/src/touch.rs index a7d3557bd..46ded9a17 100644 --- a/src/uu/touch/src/touch.rs +++ b/src/uu/touch/src/touch.rs @@ -589,8 +589,7 @@ mod tests { // We can trigger an error by not setting stdout to anything (will // fail with code 1) assert!(super::pathbuf_from_stdout() - .err() - .expect("pathbuf_from_stdout should have failed") + .expect_err("pathbuf_from_stdout should have failed") .to_string() .contains("GetFinalPathNameByHandleW failed with code 1")); }