Add line ending autodetect to 'lines' (#589)

This commit is contained in:
JT
2021-12-27 10:11:18 +11:00
committed by GitHub
parent 39f03bf5e4
commit e1c92e90ca
2 changed files with 38 additions and 18 deletions

View File

@ -84,3 +84,8 @@ fn string_in_valuestream() -> TestResult {
fn single_tick_interpolation() -> TestResult {
run_test(r#"$'(3 + 4)'"#, "7")
}
#[test]
fn detect_newlines() -> TestResult {
run_test("'hello\r\nworld' | lines | get 0 | str length", "5")
}