Skip to content

Commit

Permalink
linting
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex Harding committed Jan 5, 2024
1 parent 58b2ce8 commit 87d82b9
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
8 changes: 4 additions & 4 deletions src/store/data.js
Original file line number Diff line number Diff line change
Expand Up @@ -259,11 +259,11 @@ export default function getDataHelperFunctions() {
const upperBound = quartiles["upperQuartile"] + 1.5 * quartiles["IQR"];
if (idx) {
return data.filter(
(datum) => datum[idx] <= lowerBound || datum[idx] >= upperBound
(datum) => datum[idx] <= lowerBound || datum[idx] >= upperBound,
);
} else {
return data.filter(
(datum) => datum <= lowerBound || datum >= upperBound
(datum) => datum <= lowerBound || datum >= upperBound,
);
}
};
Expand Down Expand Up @@ -298,11 +298,11 @@ export default function getDataHelperFunctions() {
const upperBound = quartiles["upperQuartile"] + 1.5 * quartiles["IQR"];
if (idx) {
return data.filter(
(datum) => datum[idx] > lowerBound && datum[idx] < upperBound
(datum) => datum[idx] > lowerBound && datum[idx] < upperBound,
);
} else {
return data.filter(
(datum) => datum > lowerBound && datum < upperBound
(datum) => datum > lowerBound && datum < upperBound,
);
}
};
Expand Down
8 changes: 4 additions & 4 deletions tests/data.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ describe("DV Data Helpers", () => {
"1.01",
new Date(),
];
let outOfOrderArrayFlat = [4, 1, 3, 1, 2, 4]
let outOfOrderArrayFlat = [4, 1, 3, 1, 2, 4];
it("Can Validate Data", () => {
let hs = mockHs();

Expand Down Expand Up @@ -150,7 +150,7 @@ describe("DV Data Helpers", () => {
// test with all key
hs.setFilter("filter1", "all");
expect(hs.applyFilterToColumn("filter1", "test", dataArray, "all")).toEqual(
dataArray
dataArray,
);
});

Expand Down Expand Up @@ -334,7 +334,7 @@ describe("DV Data Helpers", () => {
1, 2, 96, 98,
]);
expect(
hs.getOutliers(mockSingleRowLowerThanGreaterThanObjects, "field2")
hs.getOutliers(mockSingleRowLowerThanGreaterThanObjects, "field2"),
).toEqual([
{ field1: 12, field2: 1 },
{ field1: 12, field2: 2 },
Expand Down Expand Up @@ -386,7 +386,7 @@ describe("DV Data Helpers", () => {
39, 41, 43, 45, 49, 52, 55, 57, 59,
]);
expect(
hs.removeOutliers(mockSingleRowLowerThanGreaterThanObjects, "field2")
hs.removeOutliers(mockSingleRowLowerThanGreaterThanObjects, "field2"),
).toEqual([
{ field1: 12, field2: 39 },
{ field1: 12, field2: 41 },
Expand Down
1 change: 1 addition & 0 deletions tests/mocks/pages/TestPage1.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ export default class TestPage1 {
arbitrary: "test",
};
};
//eslint-disable-next-line
extendSubscriptions = (name, args, store, pageDefinition, hook) => {
// console.log(name, args, store, pageDefinition, hook);
};
Expand Down

0 comments on commit 87d82b9

Please sign in to comment.