Allow echo to iterate ranges (#1905)

This commit is contained in:
Jonathan Turner
2020-05-28 06:07:53 +12:00
committed by GitHub
parent e2dabecc0b
commit 98a3d9fff6
3 changed files with 48 additions and 2 deletions

View File

@ -193,6 +193,18 @@ fn can_process_one_row_from_internal_and_pipes_it_to_stdin_of_external() {
assert_eq!(actual.out, "nushell");
}
#[test]
fn echoing_ranges() {
let actual = nu!(
cwd: ".",
r#"
echo 1..3 | sum
"#
);
assert_eq!(actual.out, "6");
}
mod parse {
use nu_test_support::nu;