diff --git a/tests/by-util/test_ls.rs b/tests/by-util/test_ls.rs index db2c3d445..67c649f2c 100644 --- a/tests/by-util/test_ls.rs +++ b/tests/by-util/test_ls.rs @@ -650,6 +650,15 @@ fn test_ls_width() { .stdout_only("test-width-1 test-width-2 test-width-3 test-width-4\n"); } + for option in ["-w 06", "-w=06", "--width=06", "--width 06", "--wid=06"] { + scene + .ucmd() + .args(&option.split(' ').collect::>()) + .arg("-C") + .fails() + .stderr_contains("invalid line width"); + } + scene .ucmd() .arg("-w=bad")