Sort primitives explictly. (#2016)

* Sort primitives explictly.

* Write backing up test.
This commit is contained in:
Andrés N. Robalino
2020-06-19 23:34:36 -05:00
committed by GitHub
parent fcbaefed52
commit b0c30098e4
2 changed files with 16 additions and 1 deletions

View File

@ -27,3 +27,17 @@ fn median_numbers_with_odd_rows() {
assert_eq!(actual.out, "10.5")
}
#[test]
fn median_mixed_numbers() {
let actual = nu!(
cwd: ".", pipeline(
r#"
echo [-11.5 -13.5 10]
| math median
| echo $it
"#
));
assert_eq!(actual.out, "-11.5")
}