axax
Version:
A library of async iterator extensions for JavaScript including ```map```, ```reduce```, ```filter```, ```flatMap```, ```pipe``` and [more](https://github.com/jamiemccrindle/axax/blob/master/docs/API.md#functions).
10 lines (9 loc) • 447 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const distinctUntilChanged_1 = require("../distinctUntilChanged");
const of_1 = require("../of");
const toArray_1 = require("../toArray");
test("distinctUntilChanged", async () => {
const result = await toArray_1.toArray(distinctUntilChanged_1.distinctUntilChanged()(of_1.of(0, 1, 1, 1, 3, 3, 4, 5, 6, 6, 6, 6)));
expect(result).toEqual([0, 1, 3, 4, 5, 6]);
});