deno.land / x / simplestatistics@v7.8.3 / test / unique_count_sorted.test.js

unique_count_sorted.test.js
نووسراو ببینە
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/* eslint no-shadow: 0 */
const test = require("tap").test;const uniqueCountSorted = require("../dist/simple-statistics.js").uniqueCountSorted;
test("uniqueCountSorted", function (t) { t.equal(uniqueCountSorted([]), 0); t.equal(uniqueCountSorted([1]), 1); t.equal(uniqueCountSorted([undefined]), 1); t.equal(uniqueCountSorted([1, 2, 3, 4]), 4); t.equal(uniqueCountSorted([1, 2, 3, 3, 4]), 4); t.equal(uniqueCountSorted([1, 2, 3, 3, 4, 4]), 4); t.equal(uniqueCountSorted([1, 1, 2, 3, 3, 4, 4]), 4); t.end();});
simplestatistics

Version Info

Tagged at
a year ago