From 6bcaa0b09b1cf786a75c1198a9a588233ebeae13 Mon Sep 17 00:00:00 2001 From: Jefffrey Date: Sun, 26 May 2024 12:27:26 +1000 Subject: [PATCH] doc: fix broken links in book --- book/src/proptest/tutorial/enums.md | 3 ++- book/src/proptest/tutorial/test-runner.md | 9 ++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/book/src/proptest/tutorial/enums.md b/book/src/proptest/tutorial/enums.md index 6eba15fc..8923516a 100644 --- a/book/src/proptest/tutorial/enums.md +++ b/book/src/proptest/tutorial/enums.md @@ -5,7 +5,8 @@ limited. Creating such strategies with `prop_compose!` is possible but generally is not very readable, so in most cases defining the function by hand is preferable. -The core building block is the [`prop_oneof!`](macro.prop_oneof.html) +The core building block is the +[`prop_oneof!`](https://docs.rs/proptest/latest/proptest/macro.prop_oneof.html) macro, in which you list one case for each case in your `enum`. For `enum`s which have no data, the strategy for each case is `Just(YourEnum::TheCase)`. Enum cases with data generally require putting diff --git a/book/src/proptest/tutorial/test-runner.md b/book/src/proptest/tutorial/test-runner.md index 4a296f17..5e6841e4 100644 --- a/book/src/proptest/tutorial/test-runner.md +++ b/book/src/proptest/tutorial/test-runner.md @@ -1,11 +1,10 @@ # Using the Test Runner Rather than manually shrinking, proptest's -[`TestRunner`](test_runner/struct.TestRunner.html) provides this -functionality for us and additionally handles things like panics. The -method we're interested in is `run`. We simply -give it the strategy and a function to test inputs and it takes care of the -rest. +[`TestRunner`](https://docs.rs/proptest/latest/proptest/test_runner/struct.TestRunner.html) +provides this functionality for us and additionally handles things like panics. +The method we're interested in is `run`. We simply give it the strategy and a +function to test inputs and it takes care of the rest. ```rust # extern crate proptest;