mirror of
https://github.com/nushell/nushell.git
synced 2025-06-30 14:40:06 +02:00
last, skip, drop, take until, take while, skip until, skip while, where, reverse, shuffle, append, prepend and sort-by raise error when given non-lists (#7623)
Closes https://github.com/nushell/nushell/issues/6941
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
use nu_test_support::nu;
|
||||
use nu_test_support::{nu, pipeline};
|
||||
|
||||
#[test]
|
||||
fn can_get_reverse_first() {
|
||||
@ -9,3 +9,10 @@ fn can_get_reverse_first() {
|
||||
|
||||
assert_eq!(actual.out, "utf16.ini");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn fail_on_non_iterator() {
|
||||
let actual = nu!(cwd: ".", pipeline("1 | reverse"));
|
||||
|
||||
assert!(actual.err.contains("only_supports_this_input_type"));
|
||||
}
|
||||
|
Reference in New Issue
Block a user