mirror of
https://github.com/nushell/nushell.git
synced 2025-08-16 12:07:56 +02:00
remove comment and add test for averaging integers
This commit is contained in:
@ -579,6 +579,21 @@ fn can_sum() {
|
||||
assert_eq!(actual, "203")
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn can_average() {
|
||||
let actual = nu!(
|
||||
cwd: "tests/fixtures/formats", h::pipeline(
|
||||
r#"
|
||||
open sgml_description.json
|
||||
| get glossary.GlossDiv.GlossList.GlossEntry.Sections
|
||||
| average
|
||||
| echo $it
|
||||
"#
|
||||
));
|
||||
|
||||
assert_eq!(actual, "101.5000000000000")
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn can_filter_by_unit_size_comparison() {
|
||||
let actual = nu!(
|
||||
|
Reference in New Issue
Block a user