| Crates.io | cli-snap |
| lib.rs | cli-snap |
| version | 0.1.0 |
| created_at | 2024-04-21 14:49:32.818826+00 |
| updated_at | 2024-04-21 14:49:32.818826+00 |
| description | cli-snap is a command-line interface (CLI) tool designed for testing other CLI applications using a snapshot-based testing strategy. |
| homepage | https://github.com/akhilmhdh/cli-snap |
| repository | https://github.com/akhilmhdh/cli-snap |
| max_upload_size | |
| id | 1215443 |
| size | 18,726 |
cli-snap is a command-line interface (CLI) tool designed for testing other CLI applications using a snapshot-based testing strategy.
Using cargo
cargo install cli-snap
[[tests]]
commands = ["echo 'Hello'"]
id = "hello-world"
[[tests]]
commands = ["echo 'test 2'", "echo 'second hello'"]
id = "test-2"
[config]
snapshot_directory = "./snaps"
| Ensure each test has a unique ID to distinguish and identify each snapshot.
cli-snap --config <directory where you have saved toml>

cli-snap --config <directory where you have saved toml> --update-snapshot