exit-with-code 1.0.0

A CLI which returns the exit code of your choice
1
2
3
4
5
6
7
8
9
10
11
12
#[test]
fn exit_failure() {
    let child = std::process::Command::new(env!("CARGO_BIN_EXE_ewc"))
        .arg("1")
        .spawn()
        .unwrap();

    let output = child.wait_with_output().unwrap();

    assert!(output.stderr.is_empty());
    assert!(!output.status.success());
}