2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change 7
7
![ License] ( https://img.shields.io/crates/l/assert_cmd.svg )
8
8
[ ![ Crates Status] ( https://img.shields.io/crates/v/assert_cmd.svg )] ( https://crates.io/crates/assert_cmd )
9
9
10
+ ` assert_cmd ` aims to simplify the process for doing integration testing of CLIs, including:
11
+ - Finding your crate's binary to test
12
+ - Assert on the result of your program's run.
13
+
10
14
## Install
11
15
12
16
Add to your ` Cargo.toml ` :
@@ -27,6 +31,8 @@ let mut cmd = Command::cargo_bin("bin_fixture").unwrap();
27
31
cmd.assert().success();
28
32
```
29
33
34
+ See the [ docs] ( http://docs.rs/assert_cmd ) for more.
35
+
30
36
## Relevant crates
31
37
32
38
Other crates that might be useful in testing command line programs.
Original file line number Diff line number Diff line change 1
1
//! **Assert [`Command`]** - Easy command initialization and assertions.
2
2
//!
3
- //! `assert_cmd` includes support for:
4
- //! - Setting up your program-under- test.
5
- //! - Verifying your program-under-test .
3
+ //! `assert_cmd` aims to simplify the process for doing integration testing of CLIs, including :
4
+ //! - Finding your crate's binary to test
5
+ //! - Assert on the result of your program's run .
6
6
//!
7
7
//! ```toml
8
8
//! [dependencies]
21
21
//! - `current_dir`
22
22
//! - `env` / `envs` / `env_remove` / `env_clear`
23
23
//! - `write_stdin` / `pipe_stdin`
24
+ //! - `timeout`
24
25
//!
25
26
//! Validate a [`Command`]:
26
27
//! - `ok` / `unwrap` / `unwrap_err`
0 commit comments