Skip to content

Commit

Permalink
assert.deepStrictEqual
Browse files Browse the repository at this point in the history
  • Loading branch information
mbostock committed Jul 3, 2022
1 parent 679d6da commit acc40e1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions test/linspace-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import assert from "assert";
import {linspace} from "../src/index.js";

it("linspace(start, stop)", () => {
assert.deepEqual(linspace(0, 49), [
assert.deepStrictEqual(linspace(0, 49), [
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
Expand All @@ -12,14 +12,14 @@ it("linspace(start, stop)", () => {
});

it("linspace(start, stop, n)", () => {
assert.deepEqual(linspace(2, 3, 5), [2, 2.25, 2.5, 2.75, 3]);
assert.deepStrictEqual(linspace(2, 3, 5), [2, 2.25, 2.5, 2.75, 3]);
});

it("linspace(start, stop, n, false)", () => {
assert.deepEqual(linspace(2, 3, 5, false), [2, 2.2, 2.4, 2.6, 2.8]);
assert.deepStrictEqual(linspace(2, 3, 5, false), [2, 2.2, 2.4, 2.6, 2.8]);
});

it("linspace(start, stop, n) descending", () => {
assert.deepEqual(linspace(5, 1, 5), [5, 4, 3, 2, 1]);
assert.deepEqual(linspace(5, 0, 5, false), [5, 4, 3, 2, 1]);
assert.deepStrictEqual(linspace(5, 1, 5), [5, 4, 3, 2, 1]);
assert.deepStrictEqual(linspace(5, 0, 5, false), [5, 4, 3, 2, 1]);
});

0 comments on commit acc40e1

Please sign in to comment.