From 332b34b2f29ed9806cb8b056e9f41b130266aeb7 Mon Sep 17 00:00:00 2001 From: black5box Date: Tue, 18 Nov 2025 17:53:52 +0800 Subject: [PATCH] chore: minor improvement for docs Signed-off-by: black5box --- src/path/fc.rs | 2 +- src/path/fs.rs | 1 - src/str/basics.rs | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/path/fc.rs b/src/path/fc.rs index f16c156..bcb92c7 100644 --- a/src/path/fc.rs +++ b/src/path/fc.rs @@ -22,7 +22,7 @@ fn read_file(path: &path::Path) -> io::Result> { /// Predicate adapter that converts a `path` predicate to a byte predicate on its content. /// -/// This is created by `pred.from_path()`. +/// This is created by `pred.from_file_path()`. #[derive(Debug, Clone, Copy, PartialEq, Eq)] pub struct FileContentPredicate

where diff --git a/src/path/fs.rs b/src/path/fs.rs index 9db46b2..22291ea 100644 --- a/src/path/fs.rs +++ b/src/path/fs.rs @@ -111,7 +111,6 @@ impl fmt::Display for BinaryFilePredicate { /// let predicate_file = predicate::path::eq_file(Path::new("Cargo.toml")); /// assert_eq!(true, predicate_file.eval(Path::new("Cargo.toml"))); /// assert_eq!(false, predicate_file.eval(Path::new("src"))); -/// assert_eq!(false, predicate_file.eval(Path::new("src"))); /// ``` pub fn eq_file>(path: P) -> BinaryFilePredicate { let path = path.into(); diff --git a/src/str/basics.rs b/src/str/basics.rs index 4128a8e..90b2ed8 100644 --- a/src/str/basics.rs +++ b/src/str/basics.rs @@ -168,7 +168,7 @@ where /// Predicate that checks for patterns. /// -/// This is created by `predicates::str:contains`. +/// This is created by `predicates::str::contains`. #[derive(Debug, Clone, PartialEq, Eq)] pub struct ContainsPredicate { pattern: String,