You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: guide/src/cli/test.md
+11-1Lines changed: 11 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -43,7 +43,17 @@ mdbook test path/to/book
43
43
The `--library-path` (`-L`) option allows you to add directories to the library
44
44
search path used by `rustdoc` when it builds and tests the examples. Multiple
45
45
directories can be specified with multiple options (`-L foo -L bar`) or with a
46
-
comma-delimited list (`-L foo,bar`).
46
+
comma-delimited list (`-L foo,bar`). The path should point to the Cargo
47
+
[build cache](https://doc.rust-lang.org/cargo/guide/build-cache.html)`deps` directory that
48
+
contains the build output of your project. For example, if your Rust project's book is in a directory
49
+
named `my-book`, the following command would include the crate's dependencies when running `test`:
50
+
51
+
```shell
52
+
mdbook test my-book -L target/debug/deps/
53
+
```
54
+
55
+
See the `rustdoc` command-line [documentation](https://doc.rust-lang.org/rustdoc/command-line-arguments.html#-l--library-path-where-to-look-for-dependencies)
0 commit comments