Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ docker-clean:
docker rmi -f '$(DOCKER_IMAGE)'

lint: node-deps
npm run lint . --max-warnings=0 || exit 0
npm run lint .

unit-test: node-deps
npm test
Expand Down
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,3 @@ docker-compose up --build
To execute the linter run:

`npm run lint`
Please be aware of that running the linter may flag problems/errors that already exist in the repo.
1 change: 0 additions & 1 deletion config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
'use strict';

const fs = require('fs');
const packageJson = require('./package.json');

const defaultsFalse = v => String(v || '').match(/(true|yes|on)/i) !== null;
Expand Down
29 changes: 17 additions & 12 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,21 +1,26 @@
import globals from "globals";
import pluginJs from "@eslint/js";
import tseslint from "typescript-eslint";

export default [
{
files: ["**/*.js"],
languageOptions: {
sourceType: "script",
{
files: ["**/*.js"],
languageOptions: {
sourceType: "commonjs",
globals: {
...globals.browser,
...globals.node
}
}
...globals.node,
...globals.jest,
sinon: "readonly",
before: "readonly",
chai: "readonly",
_: "readonly",
}
},
},
pluginJs.configs.recommended,
{
ignores: ['dist/']
rules: {
"no-unused-vars": "warn"
}
},
pluginJs.configs.recommended,
...tseslint.configs.recommended,
];
];
13,283 changes: 3,649 additions & 9,634 deletions package-lock.json

Large diffs are not rendered by default.

7 changes: 6 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
"test": "npm-run-all test:cover test:check-coverage",
"test:unit": "mocha --reporter spec ./test/unit",
"test:cover": "nyc --all npm run test:unit && nyc report --reporter=html --reporter=lcov",
"test:check-coverage": "nyc check-coverage --statements 50 --branches 60 --functions 60 --lines 50"
"test:check-coverage": "nyc check-coverage --statements 50 --branches 60 --functions 60 --lines 50",
"lint": "npx eslint ."
},
"repository": {
"type": "git",
Expand All @@ -33,9 +34,13 @@
"pg-promise": "^10.11.1"
},
"devDependencies": {
"@eslint/js": "^9.7.0",
"chai": "^4.3.7",
"chai-as-promised": "^7.1.1",
"chai-json-pattern": "^1.1.0",
"eslint": "^9.7.0",
"eslint-plugin-node": "^11.1.0",
"globals": "^15.8.0",
"mocha": "^10.1.0",
"nodemon": "^3.0.1",
"npm-run-all": "^4.1.5",
Expand Down
1 change: 0 additions & 1 deletion src/middleware/readiness.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
'use strict';

const errors = require('lev-restify').errors;
const promiseRejectionHandler = require('../lib/promise-rejection-handler.js');
const readiness = require('../lib/readiness');

Expand Down
1 change: 0 additions & 1 deletion test/unit/lib/postgres.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

const pgp = require('pg-promise');
const proxyquire = require('proxyquire');
const moment = require('moment');

const anyStub = sinon.stub();
const noneStub = sinon.stub();
Expand Down
1 change: 0 additions & 1 deletion test/unit/lib/table/helpers.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
'use strict';

const proxyquire = require('proxyquire');
const { key2Field } = require('../../../../src/lib/table/helpers');

describe('lib/table/helpers.js', () => {
Expand Down