Skip to content

Commit f4c64a6

Browse files
authored
chore: update ESLint setup (#35)
1 parent ac95eb0 commit f4c64a6

File tree

6 files changed

+19
-21
lines changed

6 files changed

+19
-21
lines changed

.eslintignore

Lines changed: 0 additions & 1 deletion
This file was deleted.

.eslintrc

Lines changed: 0 additions & 3 deletions
This file was deleted.

eslint.config.mjs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import appiumConfig from '@appium/eslint-config-appium-ts';
2+
import {defineConfig, globalIgnores} from 'eslint/config';
3+
4+
export default defineConfig([
5+
{
6+
extends: [appiumConfig],
7+
},
8+
{
9+
files: ['test/**/*.{js,ts}'],
10+
rules: {
11+
'func-names': 'off'
12+
}
13+
},
14+
globalIgnores(['build']),
15+
]);

package.json

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -44,22 +44,14 @@
4444
"watch": "npm run dev"
4545
},
4646
"devDependencies": {
47-
"@appium/eslint-config-appium": "^8.0.4",
48-
"@appium/eslint-config-appium-ts": "^0.x",
47+
"@appium/eslint-config-appium-ts": "^2.0.5",
4948
"@appium/tsconfig": "^0.x",
5049
"@types/bluebird": "^3.5.37",
5150
"@types/lodash": "^4.14.189",
5251
"@types/node": "^20.4.7",
53-
"@typescript-eslint/eslint-plugin": "^6.9.0",
54-
"@typescript-eslint/parser": "^6.9.0",
5552
"chai": "^4.2.0",
5653
"chai-as-promised": "^7.1.1",
57-
"eslint": "^8.46.0",
58-
"eslint-config-prettier": "^9.0.0",
59-
"eslint-import-resolver-typescript": "^3.5.5",
60-
"eslint-plugin-import": "^2.28.0",
61-
"eslint-plugin-mocha": "^10.1.0",
62-
"eslint-plugin-promise": "^6.1.1",
54+
"eslint": "^9.39.1",
6355
"mocha": "^10.0.0",
6456
"sinon": "^16.0.0",
6557
"ts-node": "^10.9.1",

test/.eslintrc

Lines changed: 0 additions & 5 deletions
This file was deleted.

test/asyncbox-specs.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ describe('retry', function () {
7979
}
8080
return times * times;
8181
};
82-
let eventuallyOkNoSleepFn = async function (times) { // eslint-disable-line require-await
82+
let eventuallyOkNoSleepFn = async function (times) {
8383
eventuallyOkFnCalls++;
8484
if (eventuallyOkFnCalls < times) {
8585
throw new Error('not ok yet');
@@ -155,7 +155,7 @@ describe('retry', function () {
155155
const start = Date.now();
156156
try {
157157
await retryInterval(3, 2000, badFnCalls);
158-
} catch (err) {
158+
} catch {
159159
(Date.now() - start).should.be.below(4100);
160160
}
161161
});

0 commit comments

Comments
 (0)