Skip to content

Commit

Permalink
chore(deps-dev): bump @appium/eslint-config-appium-ts from 0.3.3 to 1…
Browse files Browse the repository at this point in the history
….0.1 (#451)

* chore(deps-dev): bump @appium/eslint-config-appium-ts

Bumps [@appium/eslint-config-appium-ts](https://github.com/appium/appium/tree/HEAD/packages/eslint-config-appium-ts) from 0.3.3 to 1.0.1.
- [Release notes](https://github.com/appium/appium/releases)
- [Changelog](https://github.com/appium/appium/blob/master/packages/eslint-config-appium-ts/CHANGELOG.md)
- [Commits](https://github.com/appium/appium/commits/@appium/[email protected]/packages/eslint-config-appium-ts)

---
updated-dependencies:
- dependency-name: "@appium/eslint-config-appium-ts"
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>

* fix lint

* fix lint

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Kazuaki Matsuo <[email protected]>
  • Loading branch information
dependabot[bot] and KazuCocoa authored Jan 6, 2025
1 parent d03f862 commit ccbd1b9
Show file tree
Hide file tree
Showing 14 changed files with 21 additions and 32 deletions.
13 changes: 0 additions & 13 deletions .editorconfig

This file was deleted.

2 changes: 0 additions & 2 deletions .eslintignore

This file was deleted.

5 changes: 5 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import appiumConfig from '@appium/eslint-config-appium-ts';

export default [
...appiumConfig,
];
8 changes: 4 additions & 4 deletions lib/chromedriver.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ import {
getChromedriverBinaryPath,
generateLogPrefix,
} from './utils';
import semver from 'semver';
import * as semver from 'semver';
import _ from 'lodash';
import path from 'path';
import {compareVersions} from 'compare-versions';
import ChromedriverStorageClient from './storage-client/storage-client';
import { ChromedriverStorageClient } from './storage-client/storage-client';
import {toW3cCapNames, getCapValue} from './protocol-helpers';

const NEW_CD_VERSION_FORMAT_MAJOR_VERSION = 73;
Expand Down Expand Up @@ -839,7 +839,7 @@ export class Chromedriver extends events.EventEmitter {
try {
await B.promisify(cp.exec)(cmd);
this.log.debug('Successfully cleaned up old chromedrivers');
} catch (err) {
} catch {
this.log.warn('No old chromedrivers seem to exist');
}

Expand Down Expand Up @@ -878,7 +878,7 @@ export class Chromedriver extends events.EventEmitter {
try {
await this.jwproxy.command('/url', 'GET');
return true;
} catch (e) {
} catch {
return false;
}
}
Expand Down
2 changes: 1 addition & 1 deletion lib/storage-client/chromelabs.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import _ from 'lodash';
import path from 'path';
import {logger} from '@appium/support';
import semver from 'semver';
import * as semver from 'semver';
import {ARCH, CPU} from '../constants';

const log = logger.getLogger('ChromedriverChromelabsStorageClient');
Expand Down
4 changes: 2 additions & 2 deletions lib/storage-client/googleapis.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import _ from 'lodash';
import xpath from 'xpath';
import {select as xpathSelect} from 'xpath';
import {util, logger} from '@appium/support';
import {retrieveData} from '../utils';
import B from 'bluebird';
Expand Down Expand Up @@ -99,7 +99,7 @@ export async function parseGoogleapiStorageXml(xml, shouldParseNotes = true) {
const driverNodes = /** @type {Array<Node|Attr>} */ (
// @ts-expect-error Misssing Node properties are not needed.
// https://github.com/xmldom/xmldom/issues/724
xpath.select(`//*[local-name(.)='Contents']`, doc)
xpathSelect(`//*[local-name(.)='Contents']`, doc)
);
log.debug(`Parsed ${driverNodes.length} entries from storage XML`);
if (_.isEmpty(driverNodes)) {
Expand Down
2 changes: 1 addition & 1 deletion lib/storage-client/storage-client.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import {
import {parseGoogleapiStorageXml} from './googleapis';
import {parseKnownGoodVersionsWithDownloadsJson, parseLatestKnownGoodVersionsJson} from './chromelabs';
import {compareVersions} from 'compare-versions';
import semver from 'semver';
import * as semver from 'semver';

const MAX_PARALLEL_DOWNLOADS = 5;
const STORAGE_INFOS = /** @type {readonly StorageInfo[]} */ ([{
Expand Down
2 changes: 1 addition & 1 deletion lib/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type ADB from 'appium-adb';
import type { ADB } from 'appium-adb';

export interface ChromedriverOpts {
host?: string;
Expand Down
4 changes: 2 additions & 2 deletions lib/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,8 @@ const getOsInfo = _.memoize(
}
);

// @ts-expect-error
// error TS2345: Argument of type '{}' is not assignable to parameter of type 'DriverOpts<Readonly<Record<string, Constraint>>>'
// @ts-expect-error to avoid error
// TS2345: Argument of type '{}' is not assignable to parameter of type 'DriverOpts<Readonly<Record<string, Constraint>>>'
// Type '{}' is missing the following properties from type 'ServerArgs': address, allowCors, allowInsecure, basePath, and 26 more.
const getBaseDriverInstance = _.memoize(() => new BaseDriver({}, false));

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
"e2e-test": "mocha --exit --timeout 10m \"./test/functional/**/*-specs.js\""
},
"devDependencies": {
"@appium/eslint-config-appium-ts": "^0.x",
"@appium/eslint-config-appium-ts": "^1.x",
"@appium/test-support": "^3.0.0",
"@appium/tsconfig": "^0.x",
"@semantic-release/changelog": "^6.0.1",
Expand Down
3 changes: 1 addition & 2 deletions test/functional/chromedriver-e2e-specs.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ function nextState(cd) {
function nextError(cd) {
return new B((resolve) => {
cd.on(Chromedriver.EVENT_ERROR, (err) => {
// eslint-disable-line promise/prefer-await-to-callbacks
resolve(err);
});
});
Expand Down Expand Up @@ -48,7 +47,7 @@ function buildReqRes(url, method, body) {
send: (body) => {
try {
body = JSON.parse(body);
} catch (e) {}
} catch {}
res.sentBody = body;
},
};
Expand Down
2 changes: 1 addition & 1 deletion test/functional/storage-client-e2e-specs.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import ChromedriverStorageClient from '../../lib/storage-client/storage-client';
import { ChromedriverStorageClient } from '../../lib/storage-client/storage-client';
import _ from 'lodash';
import { fs, tempDir } from '@appium/support';

Expand Down
2 changes: 1 addition & 1 deletion test/helpers/install.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { fs, mkdirp } from '@appium/support';
import ChromedriverStorageClient from '../../lib/storage-client/storage-client';
import { ChromedriverStorageClient } from '../../lib/storage-client/storage-client';
import {
CD_VER, getOsInfo, getChromedriverDir,
} from '../../lib/utils';
Expand Down
2 changes: 1 addition & 1 deletion test/unit/storage-client-specs.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import ChromedriverStorageClient from '../../lib/storage-client/storage-client';
import { ChromedriverStorageClient } from '../../lib/storage-client/storage-client';
import _ from 'lodash';

describe('ChromedriverStorageClient', function () {
Expand Down

0 comments on commit ccbd1b9

Please sign in to comment.