Skip to content

Commit

Permalink
readme fixups
Browse files Browse the repository at this point in the history
  • Loading branch information
sunshowers committed Dec 25, 2024
1 parent 6afc625 commit cbc5c8b
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ datatest_stable::harness! {
of:

* `fn(&Path) -> datatest_stable::Result<()>`
* `fn(&Utf8Path) -> datatest_stable::Result<()>` (`Utf8Path` is part of the
[`camino`](https://docs.rs/camino) library, and is re-exported here for convenience.)
* `fn(&Utf8Path) -> datatest_stable::Result<()>` ([`Utf8Path`](https://docs.rs/camino/1.1.9/camino/struct.Utf8Path.html) is part of the
[`camino`](https://docs.rs/camino/1.1.9/camino/index.html) library, and is re-exported here for convenience.)
* `fn(&P, String) -> datatest_stable::Result<()>` where `P` is `Path` or `Utf8Path`. If the
extra `String` parameter is specified, the contents of the file will be loaded and passed in
as a string (erroring out if that failed).
Expand All @@ -61,14 +61,14 @@ datatest_stable::harness! {
the crate’s `Cargo.toml` is located). Absolute paths are not supported, and
will panic at runtime.

`root` is an arbitrary expression that implements `Display`, such as `&str`, or a
function call that returns a `Utf8PathBuf`.
`root` is an arbitrary expression that implements
[`Display`](https://doc.rust-lang.org/nightly/core/fmt/trait.Display.html), such as `&str`, or a function call that
returns a [`Utf8PathBuf`](https://docs.rs/camino/1.1.9/camino/struct.Utf8PathBuf.html).

* `pattern` - a regex used to match against and select each file to be tested. Extended regexes
with lookaround and backtracking are supported via the
[`fancy_regex`](https://docs.rs/fancy-regex) crate.
with lookaround and backtracking are supported via the [`fancy_regex`](https://docs.rs/fancy-regex/0.14.0/fancy_regex/index.html) crate.

`pattern` is an arbitrary expression that implements `Display`, such as
`pattern` is an arbitrary expression that implements [`Display`](https://doc.rust-lang.org/nightly/core/fmt/trait.Display.html), such as
`&str`, or a function call that returns a `String`.

The three parameters can be repeated if you have multiple sets of data-driven tests to be run:
Expand Down
14 changes: 7 additions & 7 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@
//! * `test` - The test function to be executed on each matching input. This function can be one
//! of:
//! * `fn(&Path) -> datatest_stable::Result<()>`
//! * `fn(&Utf8Path) -> datatest_stable::Result<()>` (`Utf8Path` is part of the
//! [`camino`](https://docs.rs/camino) library, and is re-exported here for convenience.)
//! * `fn(&Utf8Path) -> datatest_stable::Result<()>` ([`Utf8Path`](camino::Utf8Path) is part of the
//! [`camino`] library, and is re-exported here for convenience.)
//! * `fn(&P, String) -> datatest_stable::Result<()>` where `P` is `Path` or `Utf8Path`. If the
//! extra `String` parameter is specified, the contents of the file will be loaded and passed in
//! as a string (erroring out if that failed).
Expand All @@ -55,14 +55,14 @@
//! the crate's `Cargo.toml` is located). Absolute paths are not supported, and
//! will panic at runtime.
//!
//! `root` is an arbitrary expression that implements `Display`, such as `&str`, or a
//! function call that returns a `Utf8PathBuf`.
//! `root` is an arbitrary expression that implements
//! [`Display`](std::fmt::Display), such as `&str`, or a function call that
//! returns a [`Utf8PathBuf`](camino::Utf8PathBuf).
//!
//! * `pattern` - a regex used to match against and select each file to be tested. Extended regexes
//! with lookaround and backtracking are supported via the
//! [`fancy_regex`](https://docs.rs/fancy-regex) crate.
//! with lookaround and backtracking are supported via the [`fancy_regex`] crate.
//!
//! `pattern` is an arbitrary expression that implements `Display`, such as
//! `pattern` is an arbitrary expression that implements [`Display`](std::fmt::Display), such as
//! `&str`, or a function call that returns a `String`.
//!
//! The three parameters can be repeated if you have multiple sets of data-driven tests to be run:
Expand Down

0 comments on commit cbc5c8b

Please sign in to comment.