tests/pinky: add --lookup test

This commit is contained in:
Alexander Bakanovskii 2025-09-19 14:22:24 +03:00
parent 9e3871c6c5
commit 59bf18fd00
No known key found for this signature in database
GPG key ID: 57D2D344EC964A3A

View file

@ -90,6 +90,19 @@ fn test_short_format_i() {
assert_eq!(v_actual, v_expect);
}
#[cfg(unix)]
#[test]
#[cfg(not(target_os = "openbsd"))]
fn test_lookup() {
let args = ["--lookup"];
let ts = TestScenario::new(util_name!());
let actual = ts.ucmd().args(&args).succeeds().stdout_move_str();
let expect = unwrap_or_return!(expected_result(&ts, &[])).stdout_move_str();
let v_actual: Vec<&str> = actual.split_whitespace().collect();
let v_expect: Vec<&str> = expect.split_whitespace().collect();
assert_eq!(v_actual, v_expect);
}
#[cfg(unix)]
#[test]
#[cfg(not(target_os = "openbsd"))]