diff --git a/src/store/data.js b/src/store/data.js index 88a3ca8..80a2441 100644 --- a/src/store/data.js +++ b/src/store/data.js @@ -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, ); } }; @@ -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, ); } }; diff --git a/tests/data.spec.js b/tests/data.spec.js index a423d9a..e1126db 100644 --- a/tests/data.spec.js +++ b/tests/data.spec.js @@ -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(); @@ -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, ); }); @@ -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 }, @@ -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 }, diff --git a/tests/mocks/pages/TestPage1.js b/tests/mocks/pages/TestPage1.js index 494c212..6671031 100644 --- a/tests/mocks/pages/TestPage1.js +++ b/tests/mocks/pages/TestPage1.js @@ -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); };