1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 11:37:44 +00:00

feature(head): Introduce NLines to handle negative lines parameters

This commit is contained in:
Anuvrat Parashar 2020-05-10 21:31:58 +02:00 committed by Sylvestre Ledru
parent 7b96432eff
commit ce064dc62e
2 changed files with 35 additions and 4 deletions

View file

@ -28,6 +28,15 @@ fn test_stdin_1_line() {
.stdout_is_fixture("lorem_ipsum_1_line.expected");
}
#[test]
fn test_stdin_negative_23_line() {
new_ucmd!()
.args(&["-n", "-23"])
.pipe_in_fixture(INPUT)
.run()
.stdout_is_fixture("lorem_ipsum_1_line.expected");
}
#[test]
fn test_stdin_5_chars() {
new_ucmd!()