diff --git a/lib/reporters/default.js b/lib/reporters/default.js index 002d8e120..955a6bc0a 100644 --- a/lib/reporters/default.js +++ b/lib/reporters/default.js @@ -231,7 +231,7 @@ export default class Reporter { } case 'hook-finished': { - if (true && event.logs.length > 0) { + if (event.logs.length > 0) { this.lineWriter.writeLine(` ${this.prefixTitle(event.testFile, event.title)}`); this.writeLogs(event); } @@ -312,7 +312,7 @@ export default class Reporter { this.filesWithoutMatchedLineNumbers.add(event.testFile); this.lineWriter.writeLine(colors.error(`${figures.cross} Line numbers for ${this.relativeFile(event.testFile)} did not match any tests`)); - } else if (true && !this.failFastEnabled && fileStats.remainingTests > 0) { + } else if (!this.failFastEnabled && fileStats.remainingTests > 0) { this.lineWriter.writeLine(colors.error(`${figures.cross} ${fileStats.remainingTests} ${plur('test', fileStats.remainingTests)} remaining in ${this.relativeFile(event.testFile)}`)); } } @@ -571,17 +571,12 @@ export default class Reporter { this.lineWriter.writeLine(); if (this.failures.length > 0) { - const writeTrailingLines = this.internalErrors.length > 0 || this.sharedWorkerErrors.length > 0 || this.uncaughtExceptions.length > 0 || this.unhandledRejections.length > 0; - const lastFailure = this.failures[this.failures.length - 1]; for (const event of this.failures) { this.writeFailure(event); if (event !== lastFailure) { this.lineWriter.writeLine(); this.lineWriter.writeLine(); - } else if (!true && writeTrailingLines) { - this.lineWriter.writeLine(); - this.lineWriter.writeLine(); } } diff --git a/lib/runner.js b/lib/runner.js index 11539446e..181e28758 100644 --- a/lib/runner.js +++ b/lib/runner.js @@ -524,7 +524,7 @@ export default class Runner extends Emittery { // If a concurrent test fails, even if `failFast` is enabled it won't // stop other concurrent tests from running. const allOkays = await Promise.all(concurrentTests.map(task => this.runTest(task, contextRef.copy()))); - return allOkays.every(ok => ok); + return allOkays.every(Boolean); }); const beforeExitHandler = this.beforeExitHandler.bind(this); diff --git a/package-lock.json b/package-lock.json index bb6af6765..c2f1f9a1a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -76,7 +76,7 @@ "touch": "^3.1.0", "tsd": "^0.20.0", "typescript": "^4.7.2", - "xo": "^0.48.0", + "xo": "^0.49.0", "zen-observable": "^0.8.15" }, "engines": { @@ -872,19 +872,19 @@ "dev": true }, "node_modules/@eslint/eslintrc": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.2.0.tgz", - "integrity": "sha512-igm9SjJHNEJRiUnecP/1R5T3wKLEJ7pL6e2P+GUSfCd0dGjPYYZve08uzw8L2J8foVHFz+NGu12JxRcU2gGo6w==", + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.3.0.tgz", + "integrity": "sha512-UWW0TMTmk2d7hLcWD1/e2g5HDM/HQ3csaLSqXCfqwh4uNDuNqlaKWXmEsL4Cs41Z0KnILNvwbHAah3C2yt06kw==", "dev": true, "dependencies": { "ajv": "^6.12.4", "debug": "^4.3.2", - "espree": "^9.3.1", - "globals": "^13.9.0", - "ignore": "^4.0.6", + "espree": "^9.3.2", + "globals": "^13.15.0", + "ignore": "^5.2.0", "import-fresh": "^3.2.1", "js-yaml": "^4.1.0", - "minimatch": "^3.0.4", + "minimatch": "^3.1.2", "strip-json-comments": "^3.1.1" }, "engines": { @@ -898,9 +898,9 @@ "dev": true }, "node_modules/@eslint/eslintrc/node_modules/globals": { - "version": "13.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.12.0.tgz", - "integrity": "sha512-uS8X6lSKN2JumVoXrbUz+uG4BYG+eiawqm3qFcT7ammfbUHeCBoJMlHcec/S3krSk73/AE/f0szYFmgAA3kYZg==", + "version": "13.15.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.15.0.tgz", + "integrity": "sha512-bpzcOlgDhMG070Av0Vy5Owklpv1I6+j96GhUI7Rh7IzDCKLzboflLrrfqMu8NquDbiR4EOQk7XzJwqVJxicxog==", "dev": true, "dependencies": { "type-fest": "^0.20.2" @@ -912,15 +912,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@eslint/eslintrc/node_modules/ignore": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", - "integrity": "sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==", - "dev": true, - "engines": { - "node": ">= 4" - } - }, "node_modules/@eslint/eslintrc/node_modules/js-yaml": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", @@ -1186,7 +1177,7 @@ "node_modules/@types/json5": { "version": "0.0.29", "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", - "integrity": "sha1-7ihweulOEdK4J7y+UnC86n8+ce4=", + "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==", "dev": true }, "node_modules/@types/minimist": { @@ -1776,9 +1767,9 @@ "dev": true }, "node_modules/builtin-modules": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-3.2.0.tgz", - "integrity": "sha512-lGzLKcioL90C7wMczpkY0n/oART3MbBa8R9OFGE1rJxoVI86u4WAGfEk8Wjv10eKSyTHVGkSo3bvBylCEtk7LA==", + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-3.3.0.tgz", + "integrity": "sha512-zhaCDicdLuWN5UbN5IMnFqNMhNfo919sH85y2/ea+5Yg9TsTkeZxpL+JLbp6cgYFS4sRLp3YV4S6yDuqVWHYOw==", "dev": true, "engines": { "node": ">=6" @@ -1787,6 +1778,15 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/builtins": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/builtins/-/builtins-4.1.0.tgz", + "integrity": "sha512-1bPRZQtmKaO6h7qV1YHXNtr6nCK28k0Zo95KM4dXfILcZZwoHJBN1m3lfLv9LPkcOZlrSr+J1bzMaZFO98Yq0w==", + "dev": true, + "dependencies": { + "semver": "^7.0.0" + } + }, "node_modules/c8": { "version": "7.11.3", "resolved": "https://registry.npmjs.org/c8/-/c8-7.11.3.tgz", @@ -2052,7 +2052,7 @@ "node_modules/clean-regexp": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/clean-regexp/-/clean-regexp-1.0.0.tgz", - "integrity": "sha1-jffHquUf02h06PjQW5GAvBGj/tc=", + "integrity": "sha512-GfisEZEJvzKrmGWkvfhgzcz/BllN1USeqD2V6tg14OAOgaCD2Z/PUEuxnAZ/nPvmaHRG7a8y77p1T/IRQ4D1Hw==", "dev": true, "dependencies": { "escape-string-regexp": "^1.0.5" @@ -2064,7 +2064,7 @@ "node_modules/clean-regexp/node_modules/escape-string-regexp": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", - "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", "dev": true, "engines": { "node": ">=0.8.0" @@ -2798,12 +2798,12 @@ } }, "node_modules/eslint": { - "version": "8.10.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.10.0.tgz", - "integrity": "sha512-tcI1D9lfVec+R4LE1mNDnzoJ/f71Kl/9Cv4nG47jOueCMBrCCKYXr4AUVS7go6mWYGFD4+EoN6+eXSrEbRzXVw==", + "version": "8.16.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.16.0.tgz", + "integrity": "sha512-MBndsoXY/PeVTDJeWsYj7kLZ5hQpJOfMYLsF6LicLHQWbRDG19lK5jOix4DPl8yY4SUFcE3txy86OzFLWT+yoA==", "dev": true, "dependencies": { - "@eslint/eslintrc": "^1.2.0", + "@eslint/eslintrc": "^1.3.0", "@humanwhocodes/config-array": "^0.9.2", "ajv": "^6.10.0", "chalk": "^4.0.0", @@ -2814,14 +2814,14 @@ "eslint-scope": "^7.1.1", "eslint-utils": "^3.0.0", "eslint-visitor-keys": "^3.3.0", - "espree": "^9.3.1", + "espree": "^9.3.2", "esquery": "^1.4.0", "esutils": "^2.0.2", "fast-deep-equal": "^3.1.3", "file-entry-cache": "^6.0.1", "functional-red-black-tree": "^1.0.1", "glob-parent": "^6.0.1", - "globals": "^13.6.0", + "globals": "^13.15.0", "ignore": "^5.2.0", "import-fresh": "^3.0.0", "imurmurhash": "^0.1.4", @@ -2830,7 +2830,7 @@ "json-stable-stringify-without-jsonify": "^1.0.1", "levn": "^0.4.1", "lodash.merge": "^4.6.2", - "minimatch": "^3.0.4", + "minimatch": "^3.1.2", "natural-compare": "^1.4.0", "optionator": "^0.9.1", "regexpp": "^3.2.0", @@ -2850,9 +2850,9 @@ } }, "node_modules/eslint-config-prettier": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.3.0.tgz", - "integrity": "sha512-BgZuLUSeKzvlL/VUjx/Yb787VQ26RU3gGjA3iiFvdsp/2bMfVIWUVP7tjxtjS0e+HP409cPlPvNkQloz8C91ew==", + "version": "8.5.0", + "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.5.0.tgz", + "integrity": "sha512-obmWKLUNCnhtQRKc+tmnYuQl0pFU1ibYJQ5BGhTVB08bHe9wC8qUeG7c08dj9XX+AuPj1YSGSQIHl1pnDHZR0Q==", "dev": true, "bin": { "eslint-config-prettier": "bin/cli.js" @@ -2862,9 +2862,9 @@ } }, "node_modules/eslint-config-xo": { - "version": "0.40.0", - "resolved": "https://registry.npmjs.org/eslint-config-xo/-/eslint-config-xo-0.40.0.tgz", - "integrity": "sha512-msI1O0JGxeK2bbExg3U6EGaWKcjhOFzEjwzObywG/DC5GSNZTOyJT+b2l9MZGBeZsVdxfIGwdXTNeWXl8cN9iw==", + "version": "0.41.0", + "resolved": "https://registry.npmjs.org/eslint-config-xo/-/eslint-config-xo-0.41.0.tgz", + "integrity": "sha512-cyTc182COQVdalOi5105h0Cw/Qb52IRGyIZLmUICIauANm9Upmv81UEsuFkdKnvwr4NtU95qjdk3g4/kNspA6g==", "dev": true, "dependencies": { "confusing-browser-globals": "1.0.11" @@ -2876,7 +2876,7 @@ "url": "https://github.com/sponsors/sindresorhus" }, "peerDependencies": { - "eslint": ">=8.6.0" + "eslint": ">=8.14.0" } }, "node_modules/eslint-formatter-pretty": { @@ -3106,9 +3106,9 @@ } }, "node_modules/eslint-module-utils": { - "version": "2.7.2", - "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.7.2.tgz", - "integrity": "sha512-zquepFnWCY2ISMFwD/DqzaM++H+7PDzOpUvotJWm/y1BAFt5R4oeULgdrTejKqLkz7MA/tgstsUMNYc7wNdTrg==", + "version": "2.7.3", + "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.7.3.tgz", + "integrity": "sha512-088JEC7O3lDZM9xGe0RerkOMd0EjFl+Yvd1jPWIkMT5u3H9+HC34mWWPnqPrN13gieT9pBOO+Qt07Nb/6TresQ==", "dev": true, "dependencies": { "debug": "^3.2.7", @@ -3130,7 +3130,7 @@ "node_modules/eslint-module-utils/node_modules/find-up": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz", - "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=", + "integrity": "sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ==", "dev": true, "dependencies": { "locate-path": "^2.0.0" @@ -3142,7 +3142,7 @@ "node_modules/eslint-module-utils/node_modules/locate-path": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz", - "integrity": "sha1-K1aLJl7slExtnA3pw9u7ygNUzY4=", + "integrity": "sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA==", "dev": true, "dependencies": { "p-locate": "^2.0.0", @@ -3167,7 +3167,7 @@ "node_modules/eslint-module-utils/node_modules/p-locate": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz", - "integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=", + "integrity": "sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==", "dev": true, "dependencies": { "p-limit": "^1.1.0" @@ -3179,7 +3179,7 @@ "node_modules/eslint-module-utils/node_modules/p-try": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz", - "integrity": "sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M=", + "integrity": "sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==", "dev": true, "engines": { "node": ">=4" @@ -3188,7 +3188,7 @@ "node_modules/eslint-module-utils/node_modules/path-exists": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", "dev": true, "engines": { "node": ">=4" @@ -3300,9 +3300,9 @@ } }, "node_modules/eslint-plugin-import": { - "version": "2.25.4", - "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.25.4.tgz", - "integrity": "sha512-/KJBASVFxpu0xg1kIBn9AUa8hQVnszpwgE7Ld0lKAlx7Ie87yzEzCgSkekt+le/YVhiaosO4Y14GDAOc41nfxA==", + "version": "2.26.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.26.0.tgz", + "integrity": "sha512-hYfi3FXaM8WPLf4S1cikh/r4IxnO6zrhZbEGz2b660EJRbuxgpDS5gkCuYgGWg2xxh2rBuIr4Pvhve/7c31koA==", "dev": true, "dependencies": { "array-includes": "^3.1.4", @@ -3310,14 +3310,14 @@ "debug": "^2.6.9", "doctrine": "^2.1.0", "eslint-import-resolver-node": "^0.3.6", - "eslint-module-utils": "^2.7.2", + "eslint-module-utils": "^2.7.3", "has": "^1.0.3", - "is-core-module": "^2.8.0", + "is-core-module": "^2.8.1", "is-glob": "^4.0.3", - "minimatch": "^3.0.4", + "minimatch": "^3.1.2", "object.values": "^1.1.5", - "resolve": "^1.20.0", - "tsconfig-paths": "^3.12.0" + "resolve": "^1.22.0", + "tsconfig-paths": "^3.14.1" }, "engines": { "node": ">=4" @@ -3443,9 +3443,9 @@ } }, "node_modules/eslint-plugin-unicorn": { - "version": "40.1.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-unicorn/-/eslint-plugin-unicorn-40.1.0.tgz", - "integrity": "sha512-y5doK2DF9Sr5AqKEHbHxjFllJ167nKDRU01HDcWyv4Tnmaoe9iNxMrBnaybZvWZUaE3OC5Unu0lNIevYamloig==", + "version": "42.0.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-unicorn/-/eslint-plugin-unicorn-42.0.0.tgz", + "integrity": "sha512-ixBsbhgWuxVaNlPTT8AyfJMlhyC5flCJFjyK3oKE8TRrwBnaHvUbuIkCM1lqg8ryYrFStL/T557zfKzX4GKSlg==", "dev": true, "dependencies": { "@babel/helper-validator-identifier": "^7.15.7", @@ -3470,7 +3470,7 @@ "url": "https://github.com/sindresorhus/eslint-plugin-unicorn?sponsor=1" }, "peerDependencies": { - "eslint": ">=7.32.0" + "eslint": ">=8.8.0" } }, "node_modules/eslint-plugin-unicorn/node_modules/indent-string": { @@ -3626,9 +3626,9 @@ } }, "node_modules/eslint/node_modules/globals": { - "version": "13.12.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.12.0.tgz", - "integrity": "sha512-uS8X6lSKN2JumVoXrbUz+uG4BYG+eiawqm3qFcT7ammfbUHeCBoJMlHcec/S3krSk73/AE/f0szYFmgAA3kYZg==", + "version": "13.15.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-13.15.0.tgz", + "integrity": "sha512-bpzcOlgDhMG070Av0Vy5Owklpv1I6+j96GhUI7Rh7IzDCKLzboflLrrfqMu8NquDbiR4EOQk7XzJwqVJxicxog==", "dev": true, "dependencies": { "type-fest": "^0.20.2" @@ -3677,22 +3677,26 @@ } }, "node_modules/esm-utils": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/esm-utils/-/esm-utils-2.0.1.tgz", - "integrity": "sha512-eoz4dzSzykeh9mfRlCDTkNezD2zlPdFftiTH/5OZpE08hGpUPljh5rHDZqucIhX1Wl4cO6FDUUBp3tobvV7dWA==", + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/esm-utils/-/esm-utils-4.0.0.tgz", + "integrity": "sha512-1x5H25/8BQWV94T8+KRb1gcSdVQ3g+8P0NikggAujVaurUa0cOoR+UO8ie3y29iQO70HjNA93c9ie+qqI/8zzw==", "dev": true, + "dependencies": { + "import-meta-resolve": "1.1.1", + "url-or-path": "2.1.0" + }, "funding": { "url": "https://github.com/fisker/esm-utils?sponsor=1" } }, "node_modules/espree": { - "version": "9.3.1", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.3.1.tgz", - "integrity": "sha512-bvdyLmJMfwkV3NCRl5ZhJf22zBFo1y8bYh3VYb+bfzqNB4Je68P2sSuXyuFquzWLebHpNd2/d5uv7yoP9ISnGQ==", + "version": "9.3.2", + "resolved": "https://registry.npmjs.org/espree/-/espree-9.3.2.tgz", + "integrity": "sha512-D211tC7ZwouTIuY5x9XnS0E9sWNChB7IYKX/Xp5eQj3nFXhqmiUDB9q27y76oFl8jTg3pXcQx/bpxMfs3CIZbA==", "dev": true, "dependencies": { - "acorn": "^8.7.0", - "acorn-jsx": "^5.3.1", + "acorn": "^8.7.1", + "acorn-jsx": "^5.3.2", "eslint-visitor-keys": "^3.3.0" }, "engines": { @@ -4475,6 +4479,19 @@ "node": ">=4" } }, + "node_modules/import-meta-resolve": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/import-meta-resolve/-/import-meta-resolve-1.1.1.tgz", + "integrity": "sha512-JiTuIvVyPaUg11eTrNDx5bgQ/yMKMZffc7YSjvQeSMXy58DO2SQ8BtAf3xteZvmzvjYh14wnqNjL8XVeDy2o9A==", + "dev": true, + "dependencies": { + "builtins": "^4.0.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wooorm" + } + }, "node_modules/import-modules": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/import-modules/-/import-modules-2.1.0.tgz", @@ -4634,9 +4651,9 @@ } }, "node_modules/is-core-module": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.8.0.tgz", - "integrity": "sha512-vd15qHsaqrRL7dtH6QNuy0ndJmRDrS9HAM1CAiSifNUFv4x1a0CCVsj18hJ1mShxIG6T2i1sO78MkP56r0nYRw==", + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.9.0.tgz", + "integrity": "sha512-+5FPy5PnwmO3lvfMb0AsoPaBG+5KHUI0wYFXOtYPnVVVspTFUuMZNfNaNVRt3FZadstu2c8x23vykRW/NBoU6A==", "dev": true, "dependencies": { "has": "^1.0.3" @@ -5288,13 +5305,10 @@ "peer": true }, "node_modules/json5": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.0.tgz", - "integrity": "sha512-f+8cldu7X/y7RAJurMEJmdoKXGB/X550w2Nr3tTbezL6RwEE/iMcm+tZnXeoZtKuOq6ft8+CqzEkrIgx1fPoQA==", + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.1.tgz", + "integrity": "sha512-1hqLFMSrGHRHxav9q9gNjJ5EXznIxGVO09xQRrwplcS8qs28pZ8s8hupZAmqDwZUmVZ2Qb2jnyPOWcDH8m8dlA==", "dev": true, - "dependencies": { - "minimist": "^1.2.5" - }, "bin": { "json5": "lib/cli.js" }, @@ -5764,12 +5778,12 @@ "dev": true }, "node_modules/micromatch": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.4.tgz", - "integrity": "sha512-pRmzw/XUcwXGpD9aI9q/0XOwLNygjETJ8y0ao0wdqprrzDa4YnxLcz7fQRZr8voh8V10kGhABbNcHVk5wHgWwg==", + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.5.tgz", + "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==", "dependencies": { - "braces": "^3.0.1", - "picomatch": "^2.2.3" + "braces": "^3.0.2", + "picomatch": "^2.3.1" }, "engines": { "node": ">=8.6" @@ -5819,9 +5833,9 @@ } }, "node_modules/minimatch": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", - "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dependencies": { "brace-expansion": "^1.1.7" }, @@ -5830,9 +5844,9 @@ } }, "node_modules/minimist": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", + "version": "1.2.6", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", + "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==", "dev": true }, "node_modules/minimist-options": { @@ -6978,15 +6992,18 @@ } }, "node_modules/prettier": { - "version": "2.5.1", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.5.1.tgz", - "integrity": "sha512-vBZcPRUR5MZJwoyi3ZoyQlc1rXeEck8KgeC9AwwOn+exuxLxq5toTRDTSaVrXHxelDMHy9zlicw8u66yxoSUFg==", + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.6.2.tgz", + "integrity": "sha512-PkUpF+qoXTqhOeWL9fu7As8LXsIUZ1WYaJiY/a7McAQzxjk82OF0tibkFXVCDImZtWxbvojFjerkiLb0/q8mew==", "dev": true, "bin": { "prettier": "bin-prettier.js" }, "engines": { "node": ">=10.13.0" + }, + "funding": { + "url": "https://github.com/prettier/prettier?sponsor=1" } }, "node_modules/prettier-linter-helpers": { @@ -7358,13 +7375,17 @@ "dev": true }, "node_modules/resolve": { - "version": "1.20.0", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz", - "integrity": "sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A==", + "version": "1.22.0", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.0.tgz", + "integrity": "sha512-Hhtrw0nLeSrFQ7phPp4OOcVjLPIeMnRlr5mcnVuMe7M/7eBn98A3hmFRLoFo3DLZkivSYwhRUJTyPyWAk56WLw==", "dev": true, "dependencies": { - "is-core-module": "^2.2.0", - "path-parse": "^1.0.6" + "is-core-module": "^2.8.1", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" }, "funding": { "url": "https://github.com/sponsors/ljharb" @@ -7477,9 +7498,9 @@ } }, "node_modules/semver": { - "version": "7.3.5", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.5.tgz", - "integrity": "sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ==", + "version": "7.3.7", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.7.tgz", + "integrity": "sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g==", "dependencies": { "lru-cache": "^6.0.0" }, @@ -7880,6 +7901,18 @@ "node": ">=8" } }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "dev": true, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/tap": { "version": "16.2.0", "resolved": "https://registry.npmjs.org/tap/-/tap-16.2.0.tgz", @@ -10175,14 +10208,14 @@ "dev": true }, "node_modules/tsconfig-paths": { - "version": "3.12.0", - "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.12.0.tgz", - "integrity": "sha512-e5adrnOYT6zqVnWqZu7i/BQ3BnhzvGbjEjejFXO20lKIKpwTaupkCPgEfv4GZK1IBciJUEhYs3J3p75FdaTFVg==", + "version": "3.14.1", + "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.14.1.tgz", + "integrity": "sha512-fxDhWnFSLt3VuTwtvJt5fpwxBHg5AdKWMsgcPOOIilyjymcYVZoCQF8fvFRezCNfblEXmi+PcM1eYHeOAgXCOQ==", "dev": true, "dependencies": { "@types/json5": "^0.0.29", "json5": "^1.0.1", - "minimist": "^1.2.0", + "minimist": "^1.2.6", "strip-bom": "^3.0.0" } }, @@ -10421,6 +10454,15 @@ "punycode": "^2.1.0" } }, + "node_modules/url-or-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/url-or-path/-/url-or-path-2.1.0.tgz", + "integrity": "sha512-dsBD6GbytSMj9YDb3jVzSRENwFh50oUORnWBeSHfo0Lnwv2KMm/J4npyGy1P9rivUPsUGLjTA53XqAFqpe0nww==", + "dev": true, + "funding": { + "url": "https://github.com/fisker/url-or-path?sponsor=1" + } + }, "node_modules/uuid": { "version": "3.4.0", "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz", @@ -10760,9 +10802,9 @@ } }, "node_modules/xo": { - "version": "0.48.0", - "resolved": "https://registry.npmjs.org/xo/-/xo-0.48.0.tgz", - "integrity": "sha512-f0sbQGJoML3nwOLG7EIAJroBypmLokoGJqTPN+bI/oogKLMciqWBEiFh9Vpxnfwxafq1AkHoWrQZQWSflDCG1w==", + "version": "0.49.0", + "resolved": "https://registry.npmjs.org/xo/-/xo-0.49.0.tgz", + "integrity": "sha512-dDj1bYy3LJ/8C2XItw/lFVckZtO68C2YCx9TR8xfSLVcmael3y0SkeFse/3OMUPMvG5jG44bQ2CAI6wFTpRqVg==", "bundleDependencies": [ "@typescript-eslint/eslint-plugin", "@typescript-eslint/parser", @@ -10770,42 +10812,42 @@ ], "dev": true, "dependencies": { - "@eslint/eslintrc": "^1.0.5", + "@eslint/eslintrc": "^1.2.3", "@typescript-eslint/eslint-plugin": "*", "@typescript-eslint/parser": "*", "arrify": "^3.0.0", "cosmiconfig": "^7.0.1", "define-lazy-prop": "^3.0.0", - "eslint": "^8.8.0", - "eslint-config-prettier": "^8.3.0", - "eslint-config-xo": "^0.40.0", + "eslint": "^8.15.0", + "eslint-config-prettier": "^8.5.0", + "eslint-config-xo": "^0.41.0", "eslint-config-xo-typescript": "*", "eslint-formatter-pretty": "^4.1.0", "eslint-import-resolver-webpack": "^0.13.2", "eslint-plugin-ava": "^13.2.0", "eslint-plugin-eslint-comments": "^3.2.0", - "eslint-plugin-import": "^2.25.4", + "eslint-plugin-import": "^2.26.0", "eslint-plugin-no-use-extend-native": "^0.5.0", "eslint-plugin-node": "^11.1.0", "eslint-plugin-prettier": "^4.0.0", - "eslint-plugin-unicorn": "^40.1.0", - "esm-utils": "^2.0.1", + "eslint-plugin-unicorn": "^42.0.0", + "esm-utils": "^4.0.0", "find-cache-dir": "^3.3.2", "find-up": "^6.3.0", "get-stdin": "^9.0.0", "globby": "^13.1.1", "imurmurhash": "^0.1.4", "json-stable-stringify-without-jsonify": "^1.0.1", - "json5": "^2.2.0", + "json5": "^2.2.1", "lodash-es": "^4.17.21", "meow": "^10.1.2", - "micromatch": "^4.0.4", + "micromatch": "^4.0.5", "open-editor": "^4.0.0", - "prettier": "^2.5.1", - "semver": "^7.3.5", + "prettier": "^2.6.2", + "semver": "^7.3.7", "slash": "^4.0.0", "to-absolute-glob": "^2.0.2", - "typescript": "^4.5.5" + "typescript": "^4.6.4" }, "bin": { "xo": "cli.js" @@ -10853,25 +10895,25 @@ } }, "node_modules/xo/node_modules/@types/json-schema": { - "version": "7.0.9", + "version": "7.0.11", "dev": true, "inBundle": true, "license": "MIT" }, "node_modules/xo/node_modules/@typescript-eslint/eslint-plugin": { - "version": "5.11.0", + "version": "5.24.0", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@typescript-eslint/scope-manager": "5.11.0", - "@typescript-eslint/type-utils": "5.11.0", - "@typescript-eslint/utils": "5.11.0", - "debug": "^4.3.2", + "@typescript-eslint/scope-manager": "5.24.0", + "@typescript-eslint/type-utils": "5.24.0", + "@typescript-eslint/utils": "5.24.0", + "debug": "^4.3.4", "functional-red-black-tree": "^1.0.1", - "ignore": "^5.1.8", + "ignore": "^5.2.0", "regexpp": "^3.2.0", - "semver": "^7.3.5", + "semver": "^7.3.7", "tsutils": "^3.21.0" }, "engines": { @@ -10891,25 +10933,16 @@ } } }, - "node_modules/xo/node_modules/@typescript-eslint/eslint-plugin/node_modules/ignore": { - "version": "5.2.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">= 4" - } - }, "node_modules/xo/node_modules/@typescript-eslint/parser": { - "version": "5.11.0", + "version": "5.24.0", "dev": true, "inBundle": true, "license": "BSD-2-Clause", "dependencies": { - "@typescript-eslint/scope-manager": "5.11.0", - "@typescript-eslint/types": "5.11.0", - "@typescript-eslint/typescript-estree": "5.11.0", - "debug": "^4.3.2" + "@typescript-eslint/scope-manager": "5.24.0", + "@typescript-eslint/types": "5.24.0", + "@typescript-eslint/typescript-estree": "5.24.0", + "debug": "^4.3.4" }, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" @@ -10928,13 +10961,13 @@ } }, "node_modules/xo/node_modules/@typescript-eslint/scope-manager": { - "version": "5.11.0", + "version": "5.24.0", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "5.11.0", - "@typescript-eslint/visitor-keys": "5.11.0" + "@typescript-eslint/types": "5.24.0", + "@typescript-eslint/visitor-keys": "5.24.0" }, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" @@ -10945,13 +10978,13 @@ } }, "node_modules/xo/node_modules/@typescript-eslint/type-utils": { - "version": "5.11.0", + "version": "5.24.0", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@typescript-eslint/utils": "5.11.0", - "debug": "^4.3.2", + "@typescript-eslint/utils": "5.24.0", + "debug": "^4.3.4", "tsutils": "^3.21.0" }, "engines": { @@ -10971,7 +11004,7 @@ } }, "node_modules/xo/node_modules/@typescript-eslint/types": { - "version": "5.11.0", + "version": "5.24.0", "dev": true, "inBundle": true, "license": "MIT", @@ -10984,17 +11017,17 @@ } }, "node_modules/xo/node_modules/@typescript-eslint/typescript-estree": { - "version": "5.11.0", + "version": "5.24.0", "dev": true, "inBundle": true, "license": "BSD-2-Clause", "dependencies": { - "@typescript-eslint/types": "5.11.0", - "@typescript-eslint/visitor-keys": "5.11.0", - "debug": "^4.3.2", - "globby": "^11.0.4", + "@typescript-eslint/types": "5.24.0", + "@typescript-eslint/visitor-keys": "5.24.0", + "debug": "^4.3.4", + "globby": "^11.1.0", "is-glob": "^4.0.3", - "semver": "^7.3.5", + "semver": "^7.3.7", "tsutils": "^3.21.0" }, "engines": { @@ -11030,15 +11063,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/xo/node_modules/@typescript-eslint/typescript-estree/node_modules/ignore": { - "version": "5.2.0", - "dev": true, - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">= 4" - } - }, "node_modules/xo/node_modules/@typescript-eslint/typescript-estree/node_modules/slash": { "version": "3.0.0", "dev": true, @@ -11049,15 +11073,15 @@ } }, "node_modules/xo/node_modules/@typescript-eslint/utils": { - "version": "5.11.0", + "version": "5.24.0", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { "@types/json-schema": "^7.0.9", - "@typescript-eslint/scope-manager": "5.11.0", - "@typescript-eslint/types": "5.11.0", - "@typescript-eslint/typescript-estree": "5.11.0", + "@typescript-eslint/scope-manager": "5.24.0", + "@typescript-eslint/types": "5.24.0", + "@typescript-eslint/typescript-estree": "5.24.0", "eslint-scope": "^5.1.1", "eslint-utils": "^3.0.0" }, @@ -11073,13 +11097,13 @@ } }, "node_modules/xo/node_modules/@typescript-eslint/visitor-keys": { - "version": "5.11.0", + "version": "5.24.0", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "5.11.0", - "eslint-visitor-keys": "^3.0.0" + "@typescript-eslint/types": "5.24.0", + "eslint-visitor-keys": "^3.3.0" }, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" @@ -11141,7 +11165,7 @@ } }, "node_modules/xo/node_modules/debug": { - "version": "4.3.3", + "version": "4.3.4", "dev": true, "inBundle": true, "license": "MIT", @@ -11188,7 +11212,7 @@ } }, "node_modules/xo/node_modules/eslint-config-xo-typescript": { - "version": "0.50.0", + "version": "0.51.1", "dev": true, "inBundle": true, "license": "MIT", @@ -11199,7 +11223,7 @@ "url": "https://github.com/sponsors/sindresorhus" }, "peerDependencies": { - "@typescript-eslint/eslint-plugin": ">=5.8.0", + "@typescript-eslint/eslint-plugin": ">=5.22.0", "eslint": ">=8.0.0", "typescript": ">=4.4" } @@ -11254,7 +11278,7 @@ } }, "node_modules/xo/node_modules/eslint-visitor-keys": { - "version": "3.2.0", + "version": "3.3.0", "dev": true, "inBundle": true, "license": "Apache-2.0", @@ -11354,6 +11378,15 @@ "node": ">= 6" } }, + "node_modules/xo/node_modules/ignore": { + "version": "5.2.0", + "dev": true, + "inBundle": true, + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, "node_modules/xo/node_modules/is-extglob": { "version": "2.1.1", "dev": true, @@ -11447,13 +11480,13 @@ } }, "node_modules/xo/node_modules/micromatch": { - "version": "4.0.4", + "version": "4.0.5", "dev": true, "inBundle": true, "license": "MIT", "dependencies": { - "braces": "^3.0.1", - "picomatch": "^2.2.3" + "braces": "^3.0.2", + "picomatch": "^2.3.1" }, "engines": { "node": ">=8.6" @@ -11730,7 +11763,7 @@ } }, "node_modules/xo/node_modules/semver": { - "version": "7.3.5", + "version": "7.3.7", "dev": true, "inBundle": true, "license": "ISC", diff --git a/package.json b/package.json index b327f97ab..b89104708 100644 --- a/package.json +++ b/package.json @@ -146,7 +146,7 @@ "touch": "^3.1.0", "tsd": "^0.20.0", "typescript": "^4.7.2", - "xo": "^0.48.0", + "xo": "^0.49.0", "zen-observable": "^0.8.15" }, "peerDependencies": { diff --git a/test-d/context.ts b/test-d/context.ts index 81aafe0dd..476cddf0a 100644 --- a/test-d/context.ts +++ b/test-d/context.ts @@ -1,4 +1,4 @@ -/* eslint-disable @typescript-eslint/no-unused-vars, @typescript-eslint/no-empty-function */ +/* eslint-disable @typescript-eslint/no-empty-function */ import {expectError, expectType} from 'tsd'; import anyTest, {ExecutionContext, TestFn} from '..'; diff --git a/test-d/implementation-result.ts b/test-d/implementation-result.ts index 1286d42eb..e7a21ad52 100644 --- a/test-d/implementation-result.ts +++ b/test-d/implementation-result.ts @@ -1,4 +1,4 @@ -/* eslint-disable @typescript-eslint/no-unused-vars, @typescript-eslint/no-empty-function */ +/* eslint-disable @typescript-eslint/no-empty-function */ import test from '..'; test('return a promise-like', t => ({ diff --git a/test-d/macros.ts b/test-d/macros.ts index 9f2404329..26cf2780c 100644 --- a/test-d/macros.ts +++ b/test-d/macros.ts @@ -1,4 +1,4 @@ -/* eslint-disable no-lone-blocks, @typescript-eslint/no-unused-vars, @typescript-eslint/no-empty-function */ +/* eslint-disable no-lone-blocks, @typescript-eslint/no-empty-function */ import {expectType} from 'tsd'; import test, {ExecutionContext} from '..'; diff --git a/test-d/plugin.ts b/test-d/plugin.ts index edf1a0a0f..cd6fd4413 100644 --- a/test-d/plugin.ts +++ b/test-d/plugin.ts @@ -4,7 +4,7 @@ import * as plugin from '../plugin'; // eslint-disable-line import/extensions expectType(plugin.registerSharedWorker({filename: '', supportedProtocols: ['ava-4']})); -const factory: plugin.SharedWorker.Factory = ({negotiateProtocol}) => { // eslint-disable-line @typescript-eslint/no-unused-vars +const factory: plugin.SharedWorker.Factory = ({negotiateProtocol}) => { const protocol = negotiateProtocol(['ava-4']); expectType(protocol); diff --git a/types/assertions.d.ts b/types/assertions.d.ts index 0d2c8506b..68fd8d85b 100644 --- a/types/assertions.d.ts +++ b/types/assertions.d.ts @@ -252,7 +252,7 @@ export interface NotThrowsAsyncAssertion { (fn: () => PromiseLike, message?: string): Promise; /** Assert that the promise does not reject. You must await the result. */ - (promise: PromiseLike, message?: string): Promise; // eslint-disable-line @typescript-eslint/unified-signatures + (promise: PromiseLike, message?: string): Promise; /** Skip this assertion. */ skip(nonThrower: any, message?: string): void; @@ -311,7 +311,7 @@ export interface ThrowsAsyncAssertion { * rejection reason. Returns undefined when the assertion fails. You must await the result. The error must satisfy all * expectations. */ - (promise: PromiseLike, expectations?: ThrowsExpectation, message?: string): Promise; // eslint-disable-line @typescript-eslint/unified-signatures + (promise: PromiseLike, expectations?: ThrowsExpectation, message?: string): Promise; /** Skip this assertion. */ skip(thrower: any, expectations?: any, message?: string): void; diff --git a/types/test-fn.d.ts b/types/test-fn.d.ts index 2b206cdb6..730651ddb 100644 --- a/types/test-fn.d.ts +++ b/types/test-fn.d.ts @@ -219,7 +219,7 @@ export type MacroDeclarationOptions = export interface MacroFn { /** Declare a reusable test implementation. */ (/** The function that is executed when the macro is used. */ exec: ImplementationFn): Macro; - (declaration: MacroDeclarationOptions): Macro; // eslint-disable-line @typescript-eslint/unified-signatures + (declaration: MacroDeclarationOptions): Macro; } export interface Meta {