aboutsummaryrefslogtreecommitdiff
path: root/tests/cli_tests.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/cli_tests.rs')
-rw-r--r--tests/cli_tests.rs20
1 files changed, 10 insertions, 10 deletions
diff --git a/tests/cli_tests.rs b/tests/cli_tests.rs
index c195c5c..76c9078 100644
--- a/tests/cli_tests.rs
+++ b/tests/cli_tests.rs
@@ -6,7 +6,7 @@ fn run(expr: &str, input: &str, args: &[&str]) -> Output {
}
fn run_bytes(expr: &str, input: &[u8], args: &[&str]) -> Output {
- let mut child = Command::new(env!("CARGO_BIN_EXE_aip-filter"))
+ let mut child = Command::new(env!("CARGO_BIN_EXE_aif"))
.args(args)
.arg(expr)
.stdin(Stdio::piped())
@@ -144,7 +144,7 @@ fn empty_filter_and_print_mode() {
assert!(output.stdout.is_empty());
let path = format!("{}/README.md", env!("CARGO_MANIFEST_DIR"));
- let output = Command::new(env!("CARGO_BIN_EXE_aip-filter"))
+ let output = Command::new(env!("CARGO_BIN_EXE_aif"))
.args(["", &path])
.stdin(Stdio::null())
.output()
@@ -156,7 +156,7 @@ fn empty_filter_and_print_mode() {
#[test]
fn information_flags_succeed_and_unknown_long_options_fail() {
for flag in ["--help", "-h", "--version", "-V"] {
- let output = Command::new(env!("CARGO_BIN_EXE_aip-filter"))
+ let output = Command::new(env!("CARGO_BIN_EXE_aif"))
.arg(flag)
.stdin(Stdio::null())
.output()
@@ -169,11 +169,11 @@ fn information_flags_succeed_and_unknown_long_options_fail() {
assert!(text.contains("--max-record-bytes"));
assert!(text.contains("--version"));
} else {
- assert_eq!(text, format!("aip-filter {}\n", env!("CARGO_PKG_VERSION")));
+ assert_eq!(text, format!("aif {}\n", env!("CARGO_PKG_VERSION")));
}
}
for flag in ["--verison", "--unknown", "--print=invalid"] {
- let output = Command::new(env!("CARGO_BIN_EXE_aip-filter"))
+ let output = Command::new(env!("CARGO_BIN_EXE_aif"))
.arg(flag)
.stdin(Stdio::null())
.output()
@@ -267,7 +267,7 @@ fn filtering_multiple_files_preserves_successful_output() {
let second = dir.join("second.jsonl");
std::fs::write(&first, b"\"match first\"\n").unwrap();
std::fs::write(&second, b"invalid\n\"match second\"\n").unwrap();
- let output = Command::new(env!("CARGO_BIN_EXE_aip-filter"))
+ let output = Command::new(env!("CARGO_BIN_EXE_aif"))
.arg("match")
.arg(&first)
.arg(&second)
@@ -292,7 +292,7 @@ fn multiple_files_keep_record_boundaries_without_forcing_a_final_newline() {
for ending in ["", "\n", "\r\n"] {
std::fs::write(&first, format!("\"match first\"{ending}")).unwrap();
std::fs::write(&last, b"\"match last\"").unwrap();
- let output = Command::new(env!("CARGO_BIN_EXE_aip-filter"))
+ let output = Command::new(env!("CARGO_BIN_EXE_aif"))
.arg("match")
.args([&first, &middle, &last])
.output()
@@ -311,7 +311,7 @@ fn multiple_files_keep_record_boundaries_without_forcing_a_final_newline() {
}
std::fs::write(&first, b"raw").unwrap();
std::fs::write(&last, b"bytes").unwrap();
- let output = Command::new(env!("CARGO_BIN_EXE_aip-filter"))
+ let output = Command::new(env!("CARGO_BIN_EXE_aif"))
.arg("")
.args([&first, &last])
.output()
@@ -328,7 +328,7 @@ fn output_flush_errors_are_reported() {
use std::os::unix::net::UnixStream;
let (writer, reader) = UnixStream::pair().unwrap();
drop(reader);
- let mut child = Command::new(env!("CARGO_BIN_EXE_aip-filter"))
+ let mut child = Command::new(env!("CARGO_BIN_EXE_aif"))
.arg("foobar")
.stdin(Stdio::piped())
.stdout(Stdio::from(OwnedFd::from(writer)))
@@ -345,7 +345,7 @@ fn output_flush_errors_are_reported() {
for flag in ["--help", "--version"] {
let (writer, reader) = UnixStream::pair().unwrap();
drop(reader);
- let output = Command::new(env!("CARGO_BIN_EXE_aip-filter"))
+ let output = Command::new(env!("CARGO_BIN_EXE_aif"))
.arg(flag)
.stdin(Stdio::null())
.stdout(Stdio::from(OwnedFd::from(writer)))