This repository has been archived by the owner on Dec 29, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(boilerplate): Readme, Cargo Description
- Loading branch information
Showing
2 changed files
with
41 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,12 @@ | |
name = "assert_cli" | ||
version = "0.1.0" | ||
authors = ["Pascal Hertleif <[email protected]>"] | ||
repository = "https://github.com/killercup/assert_cli.git" | ||
homepage = "https://github.com/killercup/assert_cli" | ||
license = "MIT" | ||
readme = "README.md" | ||
documentation = "http://killercup.github.io/assert_cli/" | ||
description = "Test CLI Applications." | ||
|
||
[features] | ||
default = [] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Assert CLI | ||
|
||
> Test CLI Applications. | ||
Currently, this crate only includes basic functionality to check the output of a child process | ||
is as expected. | ||
|
||
[![Build Status](https://travis-ci.org/killercup/assert_cli.svg)](https://travis-ci.org/killercup/assert_cli) [![Coverage Status](https://coveralls.io/repos/killercup/assert_cli/badge.svg?branch=master&service=github)](https://coveralls.io/github/killercup/assert_cli?branch=master) | ||
|
||
## Example | ||
|
||
Here's a trivial example: | ||
|
||
```rust | ||
extern crate assert_cli; | ||
assert_cli::assert_cli_output("echo", &["42"], "42").unwrap(); | ||
``` | ||
|
||
And here is one that will fail: | ||
|
||
```rust,should_panic | ||
extern crate assert_cli; | ||
assert_cli::assert_cli_output("echo", &["42"], "1337").unwrap(); | ||
``` | ||
|
||
this will show a nice, colorful diff in your terminal, like this: | ||
|
||
```diff | ||
-1337 | ||
+42 | ||
``` | ||
|
||
## License | ||
|
||
MIT |