Skip to content

Commit

Permalink
document the runner configuration usage
Browse files Browse the repository at this point in the history
and how to not change anything to run with cross
  • Loading branch information
glehmann committed Jan 28, 2024
1 parent c5fec1a commit 9f7a32b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ Other crates that might be useful in testing command line programs.
* [`assert_fs`][assert_fs] for filesystem fixtures and assertions.
* or [tempfile][tempfile] for scratchpad directories.
* [dir-diff][dir-diff] for testing file side-effects.
* [cross][cross] for cross-platform testing.

[escargot]: http://docs.rs/escargot
[rexpect]: https://crates.io/crates/rexpect
Expand All @@ -41,6 +42,7 @@ Other crates that might be useful in testing command line programs.
[duct]: https://crates.io/crates/duct
[assert_fs]: https://crates.io/crates/assert_fs
[commandspec]: https://crates.io/crates/commandspec
[cross]: https://github.com/cross-rs/cross

## License

Expand All @@ -58,13 +60,13 @@ fitzgen
>
> bravo bravo WG-cli
passcod
passcod
> Running commands and dealing with output can be complex in many many ways, so assert_cmd smoothing that is excellent, very much welcome, and improves ergonomics significantly.
volks73
volks73
> I have used [assert_cmd] in other projects and I am extremely pleased with it
coreyja
coreyja
> [assert_cmd] pretty much IS my testing strategy so far, though my app under test is pretty small.
>
> This library has made it really easy to add some test coverage to my project, even when I am just learning how to write Rust!
Expand Down
6 changes: 6 additions & 0 deletions src/cargo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,12 @@ where
///
/// See the [`cargo` module documentation][crate::cargo] for caveats and workarounds.
///
/// The [`Command`] created with this method may run the binary through a runner, as configured
/// in the `CARGO_TARGET_<TRIPLET>_RUNNER` environment variable. This is useful for running
/// binaries that can't be launched directly, such as cross-compiled binaries. When using
/// this method with [cross](https://github.com/cross-rs/cross), no extra configuration is
/// needed.
///
/// # Examples
///
/// ```rust,no_run
Expand Down

0 comments on commit 9f7a32b

Please sign in to comment.