Skip to content

Commit d047cab

Browse files
committed
prepare release
1 parent 93eebf9 commit d047cab

File tree

3 files changed

+30
-12
lines changed

3 files changed

+30
-12
lines changed

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,18 @@
11
# Changelog
22

3+
## [0.2.9] - 2024-04-25
4+
5+
### Added
6+
7+
Previously, the test functions supported were `fn(&Path) -> Result<()>` and `fn(&Utf8Path) -> Result<()>`. This release adds additional supported functions:
8+
9+
- `fn(&P, String) -> datatest_stable::Result<()>` where `P` is `Path` or `Utf8Path`. If the
10+
extra `String` parameter is specified, the contents of the file will be loaded and passed in
11+
as a string (erroring out if that failed).
12+
- `fn(&P, Vec<u8>) -> datatest_stable::Result<()>` where `P` is `Path` or `Utf8Path`. If the
13+
extra `Vec<u8>` parameter is specified, the contents of the file will be
14+
loaded and passed in as a `Vec<u8>` (erroring out if that failed).
15+
316
## [0.2.8] - 2024-04-24
417

518
### Fixed
@@ -96,6 +109,7 @@ There are no functional changes in this release.
96109

97110
(Version 0.1.0 was yanked because of a metadata issue.)
98111

112+
[0.2.9]: https://github.com/nextest-rs/datatest-stable/releases/tag/datatest-stable-0.2.9
99113
[0.2.8]: https://github.com/nextest-rs/datatest-stable/releases/tag/datatest-stable-0.2.8
100114
[0.2.7]: https://github.com/nextest-rs/datatest-stable/releases/tag/datatest-stable-0.2.7
101115
[0.2.6]: https://github.com/nextest-rs/datatest-stable/releases/tag/datatest-stable-0.2.6

README.md

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,16 @@ parameters:
4242
extra `String` parameter is specified, the contents of the file will be loaded and passed in
4343
as a string (erroring out if that failed).
4444
* `fn(&P, Vec<u8>) -> datatest_stable::Result<()>` where `P` is `Path` or `Utf8Path`. If the
45-
extra `Vec<u8>` parameter is specified, are specified, the contents of the file will be
46-
loaded and passed in as a `Vec<u8>` (erroring out if that failed).
45+
extra `Vec<u8>` parameter is specified, the contents of the file will be loaded and passed
46+
in as a `Vec<u8>` (erroring out if that failed).
4747
* `root` - The path to the root directory where the input files (fixtures) live. This path is
48-
relative to the root of the crate.
49-
* `pattern` - the regex used to match against and select each file to be tested.
48+
relative to the root of the crate (the directory where the crate's `Cargo.toml` is located).
49+
* `pattern` - a regex used to match against and select each file to be tested. Extended regexes
50+
with lookaround and backtracking are supported via the
51+
[`fancy_regex`](https://docs.rs/fancy-regex) crate.
5052

5153
The three parameters can be repeated if you have multiple sets of data-driven tests to be run:
52-
`datatest_stable::harness!(testfn1, root1, pattern1, testfn2, root2, pattern2)`
54+
`datatest_stable::harness!(testfn1, root1, pattern1, testfn2, root2, pattern2)`.
5355

5456
## Examples
5557

@@ -85,7 +87,7 @@ version update; at any time, Rust versions from at least the last 6 months are s
8587
## See also
8688

8789
* [`datatest`](https://crates.io/crates/datatest): the original inspiration for this crate, with
88-
a better UI and more features but targeting nightly Rust
90+
more features but targeting nightly Rust.
8991
* [Data-driven testing](https://en.wikipedia.org/wiki/Data-driven_testing)
9092

9193
## License

src/lib.rs

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,16 @@
3939
//! extra `String` parameter is specified, the contents of the file will be loaded and passed in
4040
//! as a string (erroring out if that failed).
4141
//! * `fn(&P, Vec<u8>) -> datatest_stable::Result<()>` where `P` is `Path` or `Utf8Path`. If the
42-
//! extra `Vec<u8>` parameter is specified, are specified, the contents of the file will be
43-
//! loaded and passed in as a `Vec<u8>` (erroring out if that failed).
42+
//! extra `Vec<u8>` parameter is specified, the contents of the file will be loaded and passed
43+
//! in as a `Vec<u8>` (erroring out if that failed).
4444
//! * `root` - The path to the root directory where the input files (fixtures) live. This path is
45-
//! relative to the root of the crate.
46-
//! * `pattern` - the regex used to match against and select each file to be tested.
45+
//! relative to the root of the crate (the directory where the crate's `Cargo.toml` is located).
46+
//! * `pattern` - a regex used to match against and select each file to be tested. Extended regexes
47+
//! with lookaround and backtracking are supported via the
48+
//! [`fancy_regex`](https://docs.rs/fancy-regex) crate.
4749
//!
4850
//! The three parameters can be repeated if you have multiple sets of data-driven tests to be run:
49-
//! `datatest_stable::harness!(testfn1, root1, pattern1, testfn2, root2, pattern2)`
51+
//! `datatest_stable::harness!(testfn1, root1, pattern1, testfn2, root2, pattern2)`.
5052
//!
5153
//! # Examples
5254
//!
@@ -82,7 +84,7 @@
8284
//! # See also
8385
//!
8486
//! * [`datatest`](https://crates.io/crates/datatest): the original inspiration for this crate, with
85-
//! a better UI and more features but targeting nightly Rust
87+
//! more features but targeting nightly Rust.
8688
//! * [Data-driven testing](https://en.wikipedia.org/wiki/Data-driven_testing)
8789
8890
#![warn(missing_docs)]

0 commit comments

Comments
 (0)