Radish alpha
h
Radicle Heartwood Protocol & Stack
Radicle
Git (anonymous pull)
Log in to clone via SSH
cli-test: Complete cargo metadata
xla committed 3 years ago
commit feedf345a36c0f39e67fbd5f3fabc65c5425ac16
parent 950fae209d954ba946e74ed4990077b99da197ce
3 files changed +47 -3
modified Cargo.lock
@@ -1869,7 +1869,7 @@ dependencies = [

[[package]]
name = "radicle-cli-test"
-
version = "0.1.0"
+
version = "0.1.1"
dependencies = [
 "log",
 "pretty_assertions",
modified radicle-cli-test/Cargo.toml
@@ -1,9 +1,18 @@
[package]
name = "radicle-cli-test"
license = "MIT OR Apache-2.0"
-
version = "0.1.0"
-
authors = ["Alexis Sellier <alexis@radicle.xyz>"]
+
version = "0.1.1"
+
authors = [
+
  "Alexis Sellier <alexis@radicle.xyz>",
+
  "xla <self@xla.is>"
+
]
edition = "2021"
+
rust-version = "1.67"
+
repository = "https://github.com/radicle-dev/heartwood"
+
description = "Test your cli with markdown descriptions"
+
categories = ["development-tools::testing"]
+
keywords = ["cli", "test", "command"]
+
readme = "README.md"

[dependencies]
log = { version = "0.4", features = ["std"] }
added radicle-cli-test/README.md
@@ -0,0 +1,35 @@
+
# radicle-cli-test
+

+
Test your CLI with the help of markdown descriptions.
+

+
## Example
+

+
Test flows are described in markdown like this example:
+

+
````` markdown
+
# Echoing works
+

+
When I call echo, it answers:
+

+
```
+
$ echo "ohai"
+
ohai
+
```
+
`````
+

+
Say this is placed in `kind-echo.md`, this is what the corresponding test case
+
would look lke:
+

+
``` rust
+
use std::path::Path;
+
use radicle_cli_test::TestFormula;
+

+
#[test]
+
fn kind_echo() {
+
    TestFormula::new()
+
        .file(Path::new("./kind-echo.md"))
+
        .unwrap()
+
        .run()
+
        .unwrap();
+
}
+
```