File tree 2 files changed +11
-3
lines changed
2 files changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -420,4 +420,12 @@ renamed with `--resource-suffix` will load from the given path.
420
420
421
421
### ` --persist-doctests ` : persist doctest executables after running
422
422
423
- This feature allows the persistence of the doctest executables to the specified path.
423
+ Using this flag looks like this:
424
+
425
+ ``` bash
426
+ $ rustdoc src/lib.rs --test -Z unstable-options --persist-doctests target/rustdoctest
427
+ ```
428
+
429
+ This flag allows you to keep doctest executables around after they're compiled or run.
430
+ Usually, rustdoc will immediately discard a compiled doctest after it's been tested, but
431
+ with this option, you can keep those binaries around for farther testing.
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ error[E0425]: cannot find value `no` in this scope
12
12
3 | no
13
13
| ^^ not found in this scope
14
14
15
- thread '$DIR/failed-doctest-output.rs - OtherStruct (line 27 )' panicked at 'couldn't compile the test', src/librustdoc/test.rs:361 :13
15
+ thread '$DIR/failed-doctest-output.rs - OtherStruct (line 17 )' panicked at 'couldn't compile the test', src/librustdoc/test.rs:354 :13
16
16
note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
17
17
18
18
---- $DIR/failed-doctest-output.rs - SomeStruct (line 11) stdout ----
@@ -21,7 +21,7 @@ thread '$DIR/failed-doctest-output.rs - SomeStruct (line 11)' panicked at 'test
21
21
thread 'main' panicked at 'oh no', $DIR/failed-doctest-output.rs:3:1
22
22
note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
23
23
24
- ', src/librustdoc/test.rs:396 :17
24
+ ', src/librustdoc/test.rs:389 :17
25
25
26
26
27
27
failures:
You can’t perform that action at this time.
0 commit comments