From 8aff4a94044e727c91d22b08fe91f0a39b2dbb67 Mon Sep 17 00:00:00 2001 From: xxchan Date: Thu, 19 Dec 2024 22:10:33 +0800 Subject: [PATCH 1/3] doc: update the recommended placeholder Currently recommended `expect![[]]` is broken #37, and #38 is blocked for long time, so maybe we can update the recommendation to a safer option instead. Signed-off-by: xxchan --- src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib.rs b/src/lib.rs index 877241b..2342a66 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -113,7 +113,7 @@ //! # fn check(_: i32, _: Expect) {} //! #[test] //! fn test_division() { -//! check(92 / 2, expect![[]]) +//! check(92 / 2, expect![[""]]) //! } //! ``` //! From 7e3092f269fac2e04b307ab490033d529f6ac210 Mon Sep 17 00:00:00 2001 From: xxchan Date: Thu, 19 Dec 2024 22:13:16 +0800 Subject: [PATCH 2/3] bump version Signed-off-by: xxchan --- CHANGELOG.md | 4 ++++ Cargo.toml | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ba0eafb..128a0c2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +# 1.5.1 + +* Documentation improvements + # 1.5.0 * Make the `data` from an `ExpectFile` accessible ([#43]) diff --git a/Cargo.toml b/Cargo.toml index 86f4d75..0e3c181 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "expect-test" -version = "1.5.0" +version = "1.5.1" description = "Minimalistic snapshot testing library" keywords = ["snapshot", "testing", "expect"] categories = ["development-tools::testing"] From fc87d4e749b363d13b4f5df64dc31caf50789da8 Mon Sep 17 00:00:00 2001 From: xxchan Date: Thu, 19 Dec 2024 22:16:44 +0800 Subject: [PATCH 3/3] update README Signed-off-by: xxchan --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index b5f5ca7..d32905e 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ Updating a failing test: https://user-images.githubusercontent.com/1711539/120119633-73b3f100-c1a1-11eb-91be-4c61a23e7060.mp4 -Adding a new test: +Adding a new test: Just leave a blank `expect![[""]]` and update it: ![expect-fresh](https://user-images.githubusercontent.com/1711539/85926961-306f4500-b8a3-11ea-9369-f2373e327a3f.gif)