{"id":13478698,"url":"https://github.com/assert-rs/assert_cmd","last_synced_at":"2026-04-06T00:05:05.600Z","repository":{"id":40370060,"uuid":"135159521","full_name":"assert-rs/assert_cmd","owner":"assert-rs","description":"Assert process::Command - Easy command initialization and assertions","archived":false,"fork":false,"pushed_at":"2024-10-01T14:20:55.000Z","size":421,"stargazers_count":472,"open_issues_count":22,"forks_count":35,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-10-31T01:42:46.347Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://docs.rs/assert_cmd","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/assert-rs.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-05-28T12:42:32.000Z","updated_at":"2024-10-29T14:58:01.000Z","dependencies_parsed_at":"2023-02-08T15:46:35.888Z","dependency_job_id":"433d7a9b-0ac9-401c-b8cd-c18653261f06","html_url":"https://github.com/assert-rs/assert_cmd","commit_stats":{"total_commits":274,"total_committers":20,"mean_commits":13.7,"dds":0.2773722627737226,"last_synced_commit":"ab7423b5b95b1cff951fea3dedd05ea05cdd0d37"},"previous_names":[],"tags_count":43,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/assert-rs%2Fassert_cmd","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/assert-rs%2Fassert_cmd/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/assert-rs%2Fassert_cmd/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/assert-rs%2Fassert_cmd/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/assert-rs","download_url":"https://codeload.github.com/assert-rs/assert_cmd/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245809665,"owners_count":20676032,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-31T16:02:01.043Z","updated_at":"2025-12-12T16:56:58.270Z","avatar_url":"https://github.com/assert-rs.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":["Rust libraries"],"readme":"# assert_cmd\n\n\u003e **Assert `process::Command`** - Easy command initialization and assertions.\n\n[![Documentation](https://img.shields.io/badge/docs-master-blue.svg)][Documentation]\n![License](https://img.shields.io/crates/l/assert_cmd.svg)\n[![Crates Status](https://img.shields.io/crates/v/assert_cmd.svg)][Crates.io]\n\n`assert_cmd` aims to simplify the process for doing integration testing of CLIs, including:\n- Finding your crate's binary to test\n- Assert on the result of your program's run.\n\n## Example\n\nHere's a trivial example:\n\n```rust,no_run\nuse assert_cmd::Command;\n\nlet mut cmd = Command::cargo_bin(\"bin_fixture\").unwrap();\ncmd.assert().success();\n```\n\nSee the [docs](http://docs.rs/assert_cmd) for more.\n\n## Relevant crates\n\nOther crates that might be useful in testing command line programs.\n* [escargot][escargot] for more control over configuring the crate's binary.\n* [duct][duct] for orchestrating multiple processes.\n  * or [commandspec] for easier writing of commands\n* [rexpect][rexpect] for testing interactive programs.\n* [`assert_fs`][assert_fs] for filesystem fixtures and assertions.\n  * or [tempfile][tempfile] for scratchpad directories.\n* [dir-diff][dir-diff] for testing file side-effects.\n* [cross][cross] for cross-platform testing.\n\n[escargot]: http://docs.rs/escargot\n[rexpect]: https://crates.io/crates/rexpect\n[dir-diff]: https://crates.io/crates/dir-diff\n[tempfile]: https://crates.io/crates/tempfile\n[duct]: https://crates.io/crates/duct\n[assert_fs]: https://crates.io/crates/assert_fs\n[commandspec]: https://crates.io/crates/commandspec\n[cross]: https://github.com/cross-rs/cross\n\n## License\n\nLicensed under either of\n\n* Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or \u003chttps://www.apache.org/licenses/LICENSE-2.0\u003e)\n* MIT license ([LICENSE-MIT](LICENSE-MIT) or \u003chttps://opensource.org/license/mit\u003e)\n\nat your option.\n\n## Testimonials\n\nfitzgen\n\u003e assert_cmd is just such a pleasure to use every single time, I fall in love all over again\n\u003e\n\u003e bravo bravo WG-cli\n\npasscod\n\u003e 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.\n\nvolks73\n\u003e  I have used [assert_cmd] in other projects and I am extremely pleased with it\n\ncoreyja\n\u003e [assert_cmd] pretty much IS my testing strategy so far, though my app under test is pretty small.\n\u003e\n\u003e 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!\n\n## Contribution\n\nUnless you explicitly state otherwise, any contribution intentionally\nsubmitted for inclusion in the work by you, as defined in the Apache-2.0\nlicense, shall be dual-licensed as above, without any additional terms or\nconditions.\n\n[Crates.io]: https://crates.io/crates/assert_cmd\n[Documentation]: https://docs.rs/assert_cmd\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fassert-rs%2Fassert_cmd","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fassert-rs%2Fassert_cmd","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fassert-rs%2Fassert_cmd/lists"}