From b830568fefe5655226c64e4e96aa3344e6cea377 Mon Sep 17 00:00:00 2001 From: Timmy Willison Date: Tue, 14 Jan 2025 05:25:31 -0500 Subject: [PATCH] Tests: Migrate test runner to jquery-test-runner Closes gh-560 --- .github/workflows/browser-tests.yml | 32 +- .github/workflows/browserstack-3.x.yml | 13 +- .github/workflows/browserstack-git.yml | 9 +- .github/workflows/filestash.yml | 2 +- .github/workflows/node.js.yml | 2 +- jtr-3.x.yml | 30 + jtr-git.yml | 14 + jtr-local.yml | 23 + package-lock.json | 1205 ++++------------- package.json | 20 +- test/data/testinit.js | 4 - test/runner/browsers.js | 242 ---- test/runner/browserstack/api.js | 332 ----- .../browserstack/buildBrowserFromString.js | 20 - test/runner/browserstack/createAuthHeader.js | 7 - test/runner/browserstack/local.js | 34 - test/runner/command.js | 143 -- test/runner/createTestServer.js | 67 - test/runner/flags/browsers.js | 24 - test/runner/flags/jquery-migrate.js | 17 - test/runner/flags/jquery.js | 30 - test/runner/flags/modules.js | 16 - test/runner/lib/buildTestUrl.js | 32 - test/runner/lib/generateHash.js | 50 - test/runner/lib/getBrowserString.js | 48 - test/runner/lib/prettyMs.js | 18 - test/runner/listeners.js | 110 -- test/runner/package.json | 3 - test/runner/queue.js | 119 -- test/runner/reporter.js | 138 -- test/runner/run.js | 355 ----- test/runner/selenium/createDriver.js | 97 -- test/runner/server.js | 13 - 33 files changed, 354 insertions(+), 2915 deletions(-) create mode 100644 jtr-3.x.yml create mode 100644 jtr-git.yml create mode 100644 jtr-local.yml delete mode 100644 test/runner/browsers.js delete mode 100644 test/runner/browserstack/api.js delete mode 100644 test/runner/browserstack/buildBrowserFromString.js delete mode 100644 test/runner/browserstack/createAuthHeader.js delete mode 100644 test/runner/browserstack/local.js delete mode 100644 test/runner/command.js delete mode 100644 test/runner/createTestServer.js delete mode 100644 test/runner/flags/browsers.js delete mode 100644 test/runner/flags/jquery-migrate.js delete mode 100644 test/runner/flags/jquery.js delete mode 100644 test/runner/flags/modules.js delete mode 100644 test/runner/lib/buildTestUrl.js delete mode 100644 test/runner/lib/generateHash.js delete mode 100644 test/runner/lib/getBrowserString.js delete mode 100644 test/runner/lib/prettyMs.js delete mode 100644 test/runner/listeners.js delete mode 100644 test/runner/package.json delete mode 100644 test/runner/queue.js delete mode 100644 test/runner/reporter.js delete mode 100644 test/runner/run.js delete mode 100644 test/runner/selenium/createDriver.js delete mode 100644 test/runner/server.js diff --git a/.github/workflows/browser-tests.yml b/.github/workflows/browser-tests.yml index f71eb5fb..b982603d 100644 --- a/.github/workflows/browser-tests.yml +++ b/.github/workflows/browser-tests.yml @@ -7,7 +7,7 @@ on: - main env: - NODE_VERSION: 20.x + NODE_VERSION: 22.x jobs: test: @@ -45,14 +45,8 @@ jobs: - name: Run tests run: | npm run pretest - npm run test:unit -- -b ${{ matrix.BROWSER }} -h \ - --jquery-migrate ${{ matrix.MIGRATE_VERSION }} \ - --jquery git --jquery git.min --jquery git.slim --jquery git.slim.min \ - --jquery 3.x-git --jquery 3.x-git.min --jquery 3.x-git.slim --jquery 3.x-git.slim.min \ - --jquery 3.7.1 --jquery 3.7.1.slim \ - --jquery 3.6.4 --jquery 3.5.1 --jquery 3.4.1 \ - --jquery 3.3.1 --jquery 3.2.1 --jquery 3.1.1 --jquery 3.0.0 \ - --retries 1 + npm run test:unit -- -c jtr-local.yml \ + --headless -b ${{ matrix.BROWSER }} -f plugin=${{ matrix.MIGRATE_VERSION }} ie: runs-on: windows-latest @@ -81,15 +75,7 @@ jobs: - name: Run tests shell: cmd - run: | - npm run test:ie -- ^ - --jquery-migrate ${{ env.MIGRATE_VERSION }} ^ - --jquery git --jquery git.min --jquery git.slim --jquery git.slim.min ^ - --jquery 3.x-git --jquery 3.x-git.min --jquery 3.x-git.slim --jquery 3.x-git.slim.min ^ - --jquery 3.7.1 --jquery 3.7.1.slim ^ - --jquery 3.6.4 --jquery 3.5.1 --jquery 3.4.1 ^ - --jquery 3.3.1 --jquery 3.2.1 --jquery 3.1.1 --jquery 3.0.0 ^ - --retries 1 + run: npm run test:ie -- -c jtr-local.yml -f plugin=${{ env.MIGRATE_VERSION }} safari: runs-on: macos-latest @@ -117,12 +103,4 @@ jobs: run: npm install - name: Run tests - run: | - npm run test:safari -- \ - --jquery-migrate ${{ env.MIGRATE_VERSION }} \ - --jquery git --jquery git.min --jquery git.slim --jquery git.slim.min \ - --jquery 3.x-git --jquery 3.x-git.min --jquery 3.x-git.slim --jquery 3.x-git.slim.min \ - --jquery 3.7.1 --jquery 3.7.1.slim \ - --jquery 3.6.4 --jquery 3.5.1 --jquery 3.4.1 \ - --jquery 3.3.1 --jquery 3.2.1 --jquery 3.1.1 --jquery 3.0.0 \ - --retries 1 + run: npm run test:safari -- -c jtr-local.yml -f plugin=${{ env.MIGRATE_VERSION }} diff --git a/.github/workflows/browserstack-3.x.yml b/.github/workflows/browserstack-3.x.yml index 6d24c606..fd62a28e 100644 --- a/.github/workflows/browserstack-3.x.yml +++ b/.github/workflows/browserstack-3.x.yml @@ -15,7 +15,7 @@ jobs: env: BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }} BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }} - NODE_VERSION: 20.x + NODE_VERSION: 22.x name: ${{ matrix.BROWSER }} concurrency: group: ${{ matrix.BROWSER }} - ${{ github.sha }} @@ -79,13 +79,6 @@ jobs: - name: Test run: | - npm run test:unit -- \ - -v --browserstack "${{ matrix.BROWSER }}" \ - --jquery-migrate dev --jquery-migrate min \ - --jquery 3.x-git --jquery 3.x-git.min --jquery 3.x-git.slim --jquery 3.x-git.slim.min \ - --jquery 3.7.1 --jquery 3.7.1.slim --jquery 3.6.4 --jquery 3.6.4.slim \ - --jquery 3.5.1 --jquery 3.5.1.slim --jquery 3.4.1 --jquery 3.4.1.slim \ - --jquery 3.3.1 --jquery 3.3.1.slim --jquery 3.2.1 --jquery 3.2.1.slim \ - --jquery 3.1.1 --jquery 3.1.1.slim --jquery 3.0.0 --jquery 3.0.0.slim \ + npm run test:unit -- -v -c jtr-3.x.yml \ + --browserstack "${{ matrix.BROWSER }}" \ --run-id ${{ github.run_id }} \ - --retries 3 --hard-retries 1 diff --git a/.github/workflows/browserstack-git.yml b/.github/workflows/browserstack-git.yml index aad19e6a..0a3d2d0c 100644 --- a/.github/workflows/browserstack-git.yml +++ b/.github/workflows/browserstack-git.yml @@ -15,7 +15,7 @@ jobs: env: BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }} BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }} - NODE_VERSION: 20.x + NODE_VERSION: 22.x name: ${{ matrix.BROWSER }} concurrency: group: ${{ matrix.BROWSER }} - ${{ github.sha }} @@ -63,9 +63,6 @@ jobs: - name: Test run: | - npm run test:unit -- \ - -v --browserstack "${{ matrix.BROWSER }}" \ - --jquery-migrate dev --jquery-migrate min \ - --jquery git --jquery git.min --jquery git.slim --jquery git.slim.min \ + npm run test:unit -- -v -c jtr-git.yml \ + --browserstack "${{ matrix.BROWSER }}" \ --run-id ${{ github.run_id }} \ - --retries 3 --hard-retries 1 diff --git a/.github/workflows/filestash.yml b/.github/workflows/filestash.yml index 9313d6ac..1bd552f0 100644 --- a/.github/workflows/filestash.yml +++ b/.github/workflows/filestash.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest environment: filestash env: - NODE_VERSION: 20.x + NODE_VERSION: 22.x name: Update Filestash steps: - name: Checkout diff --git a/.github/workflows/node.js.yml b/.github/workflows/node.js.yml index dbc107f8..74a0c6fb 100644 --- a/.github/workflows/node.js.yml +++ b/.github/workflows/node.js.yml @@ -6,7 +6,7 @@ on: branches-ignore: "dependabot/**" env: - NODE_VERSION: 20.x + NODE_VERSION: 22.x jobs: node-smoke-test: diff --git a/jtr-3.x.yml b/jtr-3.x.yml new file mode 100644 index 00000000..ecab32bc --- /dev/null +++ b/jtr-3.x.yml @@ -0,0 +1,30 @@ +version: 1 + +runs: + jquery: + - 3.x-git + - 3.x-git.min + - 3.x-git.slim + - 3.x-git.slim.min + - 3.7.1 + - 3.7.1.slim + - 3.6.4 + - 3.6.4.slim + - 3.5.1 + - 3.5.1.slim + - 3.4.1 + - 3.4.1.slim + - 3.3.1 + - 3.3.1.slim + - 3.2.1 + - 3.2.1.slim + - 3.1.1 + - 3.1.1.slim + - 3.0.0 + - 3.0.0.slim + plugin: + - dev + - min + +retries: 2 +hard-retries: 1 diff --git a/jtr-git.yml b/jtr-git.yml new file mode 100644 index 00000000..ff5ef485 --- /dev/null +++ b/jtr-git.yml @@ -0,0 +1,14 @@ +version: 1 + +runs: + jquery: + - git + - git.min + - git.slim + - git.slim.min + plugin: + - dev + - min + +retries: 2 +hard-retries: 1 diff --git a/jtr-local.yml b/jtr-local.yml new file mode 100644 index 00000000..fa5058e1 --- /dev/null +++ b/jtr-local.yml @@ -0,0 +1,23 @@ +version: 1 + +flags: + jquery: + - git + - git.min + - git.slim + - git.slim.min + - 3.x-git + - 3.x-git.min + - 3.x-git.slim + - 3.x-git.slim.min + - 3.7.1 + - 3.7.1.slim + - 3.6.4 + - 3.5.1 + - 3.4.1 + - 3.3.1 + - 3.2.1 + - 3.1.1 + - 3.0.0 + +retries: 1 diff --git a/package-lock.json b/package-lock.json index 5a280c90..96b7569f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,35 +9,34 @@ "version": "3.5.3-pre", "license": "MIT", "devDependencies": { - "@types/selenium-webdriver": "4.1.22", - "body-parser": "1.20.3", - "browserstack-local": "1.5.5", - "chalk": "5.3.0", + "chalk": "5.4.1", "commitplease": "3.2.0", - "diff": "5.2.0", "enquirer": "2.4.1", "eslint": "8.57.0", "eslint-config-jquery": "3.0.2", "eslint-plugin-import": "2.29.1", - "exit-hook": "4.0.0", - "express": "4.21.1", - "express-body-parser-error-handler": "1.0.7", "globals": "15.3.0", "husky": "9.0.11", "jquery": "3.7.1", + "jquery-test-runner": "0.2.1", "jsdom": "24.1.0", "native-promise-only": "0.8.1", "qunit": "2.21.0", "rollup": "4.22.4", - "selenium-webdriver": "4.21.0", "sinon": "7.5.0", - "uglify-js": "3.9.4", - "yargs": "17.7.2" + "uglify-js": "3.9.4" }, "peerDependencies": { "jquery": ">=3 <4" } }, + "node_modules/@bazel/runfiles": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/@bazel/runfiles/-/runfiles-6.3.1.tgz", + "integrity": "sha512-1uLNT5NZsUVIGS4syuHwTzZ8HycMPyr6POA3FCE4GbMtc4rhoJk8aZKtNIRthJYfL+iioppi+rTfH3olMPr9nA==", + "dev": true, + "license": "Apache-2.0" + }, "node_modules/@eslint-community/eslint-utils": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", @@ -85,23 +84,6 @@ "url": "https://opencollective.com/eslint" } }, - "node_modules/@eslint/eslintrc/node_modules/debug": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", - "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "dev": true, - "dependencies": { - "ms": "2.1.2" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, "node_modules/@eslint/eslintrc/node_modules/globals": { "version": "13.24.0", "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", @@ -117,12 +99,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@eslint/eslintrc/node_modules/ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, "node_modules/@eslint/js": { "version": "8.57.0", "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.57.0.tgz", @@ -146,29 +122,6 @@ "node": ">=10.10.0" } }, - "node_modules/@humanwhocodes/config-array/node_modules/debug": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", - "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "dev": true, - "dependencies": { - "ms": "2.1.2" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, - "node_modules/@humanwhocodes/config-array/node_modules/ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, "node_modules/@humanwhocodes/module-importer": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", @@ -471,152 +424,24 @@ "dev": true, "license": "(Unlicense OR Apache-2.0)" }, - "node_modules/@types/body-parser": { - "version": "1.19.5", - "resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.19.5.tgz", - "integrity": "sha512-fB3Zu92ucau0iQ0JMCFQE7b/dv8Ot07NI3KaZIkIUNXq82k4eBAqUaneXfleGY9JWskeS9y+u0nXMyspcuQrCg==", - "dev": true, - "dependencies": { - "@types/connect": "*", - "@types/node": "*" - } - }, - "node_modules/@types/connect": { - "version": "3.4.38", - "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.38.tgz", - "integrity": "sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==", - "dev": true, - "dependencies": { - "@types/node": "*" - } - }, "node_modules/@types/estree": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz", "integrity": "sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==", "dev": true }, - "node_modules/@types/express": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/@types/express/-/express-4.17.21.tgz", - "integrity": "sha512-ejlPM315qwLpaQlQDTjPdsUFSc6ZsP4AN6AlWnogPjQ7CVi7PYF3YVz+CY3jE2pwYf7E/7HlDAN0rV2GxTG0HQ==", - "dev": true, - "dependencies": { - "@types/body-parser": "*", - "@types/express-serve-static-core": "^4.17.33", - "@types/qs": "*", - "@types/serve-static": "*" - } - }, - "node_modules/@types/express-serve-static-core": { - "version": "4.19.2", - "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.19.2.tgz", - "integrity": "sha512-dPSEQElyVJ97BuGduAqQjpBocZWAs0GR94z+ptL7JXQJeJdHw2WBG3EWdFrK36b8Q6j8P4cXOMhgUoi0IIfIsg==", - "dev": true, - "dependencies": { - "@types/node": "*", - "@types/qs": "*", - "@types/range-parser": "*", - "@types/send": "*" - } - }, - "node_modules/@types/http-errors": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/@types/http-errors/-/http-errors-2.0.4.tgz", - "integrity": "sha512-D0CFMMtydbJAegzOyHjtiKPLlvnm3iTZyZRSZoLq2mRhDdmLfIWOCYPfQJ4cu2erKghU++QvjcUjp/5h7hESpA==", - "dev": true - }, "node_modules/@types/json5": { "version": "0.0.29", "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz", "integrity": "sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==", "dev": true }, - "node_modules/@types/mime": { - "version": "1.3.5", - "resolved": "https://registry.npmjs.org/@types/mime/-/mime-1.3.5.tgz", - "integrity": "sha512-/pyBZWSLD2n0dcHE3hq8s8ZvcETHtEuF+3E7XVt0Ig2nvsVQXdghHVcEkIWjy9A0wKfTn97a/PSDYohKIlnP/w==", - "dev": true - }, - "node_modules/@types/node": { - "version": "20.12.13", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.12.13.tgz", - "integrity": "sha512-gBGeanV41c1L171rR7wjbMiEpEI/l5XFQdLLfhr/REwpgDy/4U8y89+i8kRiLzDyZdOkXh+cRaTetUnCYutoXA==", - "dev": true, - "dependencies": { - "undici-types": "~5.26.4" - } - }, - "node_modules/@types/qs": { - "version": "6.9.15", - "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.15.tgz", - "integrity": "sha512-uXHQKES6DQKKCLh441Xv/dwxOq1TVS3JPUMlEqoEglvlhR6Mxnlew/Xq/LRVHpLyk7iK3zODe1qYHIMltO7XGg==", - "dev": true - }, - "node_modules/@types/range-parser": { - "version": "1.2.7", - "resolved": "https://registry.npmjs.org/@types/range-parser/-/range-parser-1.2.7.tgz", - "integrity": "sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==", - "dev": true - }, - "node_modules/@types/selenium-webdriver": { - "version": "4.1.22", - "resolved": "https://registry.npmjs.org/@types/selenium-webdriver/-/selenium-webdriver-4.1.22.tgz", - "integrity": "sha512-MCL4l7q8dwxejr2Q2NXLyNwHWMPdlWE0Kpn6fFwJtvkJF7PTkG5jkvbH/X1IAAQxgt/L1dA8u2GtDeekvSKvOA==", - "dev": true, - "dependencies": { - "@types/ws": "*" - } - }, - "node_modules/@types/send": { - "version": "0.17.4", - "resolved": "https://registry.npmjs.org/@types/send/-/send-0.17.4.tgz", - "integrity": "sha512-x2EM6TJOybec7c52BX0ZspPodMsQUd5L6PRwOunVyVUhXiBSKf3AezDL8Dgvgt5o0UfKNfuA0eMLr2wLT4AiBA==", - "dev": true, - "dependencies": { - "@types/mime": "^1", - "@types/node": "*" - } - }, - "node_modules/@types/serve-static": { - "version": "1.15.7", - "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.15.7.tgz", - "integrity": "sha512-W8Ym+h8nhuRwaKPaDw34QUkwsGi6Rc4yYqvKFo5rm2FUEhCFbzVWrxXUxuKK8TASjWsysJY0nsmNCGhCOIsrOw==", - "dev": true, - "dependencies": { - "@types/http-errors": "*", - "@types/node": "*", - "@types/send": "*" - } - }, - "node_modules/@types/ws": { - "version": "8.5.10", - "resolved": "https://registry.npmjs.org/@types/ws/-/ws-8.5.10.tgz", - "integrity": "sha512-vmQSUcfalpIq0R9q7uTo2lXs6eGIpt9wtnLdMv9LVpIjCA/+ufZRozlVoVelIYixx1ugCBKDhn89vnsEGOCx9A==", - "dev": true, - "dependencies": { - "@types/node": "*" - } - }, "node_modules/@ungap/structured-clone": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/@ungap/structured-clone/-/structured-clone-1.2.0.tgz", "integrity": "sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==", "dev": true }, - "node_modules/accepts": { - "version": "1.3.8", - "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", - "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", - "dev": true, - "dependencies": { - "mime-types": "~2.1.34", - "negotiator": "0.6.3" - }, - "engines": { - "node": ">= 0.6" - } - }, "node_modules/acorn": { "version": "8.11.3", "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.11.3.tgz", @@ -643,6 +468,7 @@ "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", "dev": true, + "license": "MIT", "dependencies": { "debug": "4" }, @@ -650,29 +476,6 @@ "node": ">= 6.0.0" } }, - "node_modules/agent-base/node_modules/debug": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", - "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "dev": true, - "dependencies": { - "ms": "2.1.2" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, - "node_modules/agent-base/node_modules/ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, "node_modules/ajv": { "version": "6.12.6", "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", @@ -694,6 +497,7 @@ "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", "dev": true, + "license": "MIT", "engines": { "node": ">=6" } @@ -744,12 +548,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/array-flatten": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", - "integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==", - "dev": true - }, "node_modules/array-from": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/array-from/-/array-from-2.1.1.tgz", @@ -882,30 +680,6 @@ "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", "dev": true }, - "node_modules/body-parser": { - "version": "1.20.3", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", - "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", - "dev": true, - "dependencies": { - "bytes": "3.1.2", - "content-type": "~1.0.5", - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.13.0", - "raw-body": "2.5.2", - "type-is": "~1.6.18", - "unpipe": "1.0.0" - }, - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" - } - }, "node_modules/brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -917,10 +691,11 @@ } }, "node_modules/browserstack-local": { - "version": "1.5.5", - "resolved": "https://registry.npmjs.org/browserstack-local/-/browserstack-local-1.5.5.tgz", - "integrity": "sha512-jKne7yosrMcptj3hqxp36TP9k0ZW2sCqhyurX24rUL4G3eT7OLgv+CSQN8iq5dtkv5IK+g+v8fWvsiC/S9KxMg==", + "version": "1.5.6", + "resolved": "https://registry.npmjs.org/browserstack-local/-/browserstack-local-1.5.6.tgz", + "integrity": "sha512-s0GadAkyE1XHxnmymb9atogTZbA654bcFpqGkcYEtYPaPvuvVfSXR0gw8ojn0I0Td2HEMJcGtdrkBjb1Fi/HmQ==", "dev": true, + "license": "MIT", "dependencies": { "agent-base": "^6.0.2", "https-proxy-agent": "^5.0.1", @@ -934,6 +709,7 @@ "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.8" } @@ -967,10 +743,11 @@ } }, "node_modules/chalk": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.3.0.tgz", - "integrity": "sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==", + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.4.1.tgz", + "integrity": "sha512-zgVZuo2WcZgfUEmsn6eO3kINexW8RAE4maiQ8QNs8CtpPCSyMiYsULR3HQYkm3w8FIA3SberyMJMSldGsW+U3w==", "dev": true, + "license": "MIT", "engines": { "node": "^12.17.0 || ^14.13 || >=16.0.0" }, @@ -978,20 +755,6 @@ "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/cliui": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", - "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", - "dev": true, - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.1", - "wrap-ansi": "^7.0.0" - }, - "engines": { - "node": ">=12" - } - }, "node_modules/color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", @@ -1108,47 +871,12 @@ "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", "dev": true }, - "node_modules/content-disposition": { - "version": "0.5.4", - "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.4.tgz", - "integrity": "sha512-FveZTNuGw04cxlAiWbzi6zTAL/lhehaWbTtgluJh4/E95DqMwTmha3KZN1aAWA8cFIhHzMZUvLevkw5Rqk+tSQ==", - "dev": true, - "dependencies": { - "safe-buffer": "5.2.1" - }, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/content-type": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.5.tgz", - "integrity": "sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/cookie": { - "version": "0.7.1", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.1.tgz", - "integrity": "sha512-6DnInpx7SJ2AK3+CTUE/ZM0vWTUboZCegxhC2xiIydHR9jNuTAASBrfEpHhiGOZw/nX51bHt6YQl8jsGo4y/0w==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/cookie-signature": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", - "integrity": "sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==", - "dev": true - }, "node_modules/core-util-is": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/cross-spawn": { "version": "7.0.3", @@ -1165,23 +893,18 @@ } }, "node_modules/cssstyle": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-4.0.1.tgz", - "integrity": "sha512-8ZYiJ3A/3OkDd093CBT/0UKDWry7ak4BdPTFP2+QEP7cmhouyq/Up709ASSj2cK02BbZiMgk7kYjZNS4QP5qrQ==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-4.1.0.tgz", + "integrity": "sha512-h66W1URKpBS5YMI/V8PyXvTMFT8SupJ1IzoIV8IeBC/ji8WVmrO8dGlTi+2dh6whmdk6BiKJLD/ZBkhWbcg6nA==", "dev": true, + "license": "MIT", "dependencies": { - "rrweb-cssom": "^0.6.0" + "rrweb-cssom": "^0.7.1" }, "engines": { "node": ">=18" } }, - "node_modules/cssstyle/node_modules/rrweb-cssom": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/rrweb-cssom/-/rrweb-cssom-0.6.0.tgz", - "integrity": "sha512-APM0Gt1KoXBz0iIkkdB/kfvGOwC4UuJFeG/c+yV7wSc7q96cG/kJ0HiYCnzivD9SB53cLV1MlHFNfOuPaadYSw==", - "dev": true - }, "node_modules/data-urls": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/data-urls/-/data-urls-5.0.0.tgz", @@ -1247,12 +970,21 @@ } }, "node_modules/debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.0.tgz", + "integrity": "sha512-6WTZ/IxCY/T6BALoZHaE4ctp9xm+Z5kY/pzYaCHRFeyVhojxlrm+46y68HA6hr0TcwEssoxNiDEUJQjfPZ/RYA==", "dev": true, + "license": "MIT", "dependencies": { - "ms": "2.0.0" + "ms": "^2.1.3" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } } }, "node_modules/decimal.js": { @@ -1315,25 +1047,17 @@ "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.8" } }, - "node_modules/destroy": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.2.0.tgz", - "integrity": "sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg==", - "dev": true, - "engines": { - "node": ">= 0.8", - "npm": "1.2.8000 || >= 1.4.16" - } - }, "node_modules/diff": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-5.2.0.tgz", - "integrity": "sha512-uIFDxqpRZGZ6ThOk84hEfqWoHx2devRFvpTZcTHur85vImfaxUbTW9Ryh4CpCuDnToOP1CEtXKIgytHBPVff5A==", + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/diff/-/diff-7.0.0.tgz", + "integrity": "sha512-PJWHUb1RFevKCwaFA9RlG5tCd+FO5iRh9A8HEtkmBH2Li03iJriB6m6JIN4rGz3K3JLawI7/veA1xzRKP6ISBw==", "dev": true, + "license": "BSD-3-Clause", "engines": { "node": ">=0.3.1" } @@ -1354,34 +1078,15 @@ "version": "0.1.2", "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==", - "dev": true - }, - "node_modules/ee-first": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", - "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==", - "dev": true - }, - "node_modules/emoji-regex": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", - "dev": true - }, - "node_modules/encodeurl": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.0.tgz", - "integrity": "sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==", "dev": true, - "engines": { - "node": ">= 0.8" - } + "license": "MIT" }, "node_modules/enquirer": { "version": "2.4.1", "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.4.1.tgz", "integrity": "sha512-rRqJg/6gd538VHvR3PSrdRBb/1Vy2YfzHqzvbhGIQpDRKIa4FgV/54b5Q1xYSxOOwKvjXweS26E0Q+nAMwp2pQ==", "dev": true, + "license": "MIT", "dependencies": { "ansi-colors": "^4.1.1", "strip-ansi": "^6.0.1" @@ -1535,21 +1240,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/escalade": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.2.tgz", - "integrity": "sha512-ErCHMCae19vR8vQGe50xIsVomy19rg6gFu3+r3jkEO46suLMWBksvVyoGgQV+jOfl84ZSOSlmv6Gxa89PmTGmA==", - "dev": true, - "engines": { - "node": ">=6" - } - }, - "node_modules/escape-html": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", - "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==", - "dev": true - }, "node_modules/escape-string-regexp": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", @@ -1643,12 +1333,6 @@ "ms": "^2.1.1" } }, - "node_modules/eslint-import-resolver-node/node_modules/ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "dev": true - }, "node_modules/eslint-module-utils": { "version": "2.8.1", "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.8.1.tgz", @@ -1675,12 +1359,6 @@ "ms": "^2.1.1" } }, - "node_modules/eslint-module-utils/node_modules/ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "dev": true - }, "node_modules/eslint-plugin-import": { "version": "2.29.1", "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.29.1.tgz", @@ -1733,12 +1411,6 @@ "node": ">=0.10.0" } }, - "node_modules/eslint-plugin-import/node_modules/ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "dev": true - }, "node_modules/eslint-plugin-import/node_modules/semver": { "version": "6.3.1", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", @@ -1792,23 +1464,6 @@ "url": "https://github.com/chalk/chalk?sponsor=1" } }, - "node_modules/eslint/node_modules/debug": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", - "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "dev": true, - "dependencies": { - "ms": "2.1.2" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, "node_modules/eslint/node_modules/globals": { "version": "13.24.0", "resolved": "https://registry.npmjs.org/globals/-/globals-13.24.0.tgz", @@ -1824,12 +1479,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint/node_modules/ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, "node_modules/eslint/node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", @@ -1901,20 +1550,12 @@ "node": ">=0.10.0" } }, - "node_modules/etag": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", - "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, "node_modules/event-stream": { "version": "3.3.4", "resolved": "https://registry.npmjs.org/event-stream/-/event-stream-3.3.4.tgz", "integrity": "sha512-QHpkERcGsR0T7Qm3HNJSyXKEEj8AHNxkY3PK8TS2KJvQ7NiSHe3DDpwVKKtoYprL/AreyzFBeIkBIWChAqn60g==", "dev": true, + "license": "MIT", "dependencies": { "duplexer": "~0.1.1", "from": "~0", @@ -1930,6 +1571,7 @@ "resolved": "https://registry.npmjs.org/exit-hook/-/exit-hook-4.0.0.tgz", "integrity": "sha512-Fqs7ChZm72y40wKjOFXBKg7nJZvQJmewP5/7LtePDdnah/+FH9Hp5sgMujSCMPXlxOAW2//1jrW9pnsY7o20vQ==", "dev": true, + "license": "MIT", "engines": { "node": ">=18" }, @@ -1937,57 +1579,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/express": { - "version": "4.21.1", - "resolved": "https://registry.npmjs.org/express/-/express-4.21.1.tgz", - "integrity": "sha512-YSFlK1Ee0/GC8QaO91tHcDxJiE/X4FbpAyQWkxAvG6AXCuR65YzK8ua6D9hvi/TzUfZMpc+BwuM1IPw8fmQBiQ==", - "dev": true, - "dependencies": { - "accepts": "~1.3.8", - "array-flatten": "1.1.1", - "body-parser": "1.20.3", - "content-disposition": "0.5.4", - "content-type": "~1.0.4", - "cookie": "0.7.1", - "cookie-signature": "1.0.6", - "debug": "2.6.9", - "depd": "2.0.0", - "encodeurl": "~2.0.0", - "escape-html": "~1.0.3", - "etag": "~1.8.1", - "finalhandler": "1.3.1", - "fresh": "0.5.2", - "http-errors": "2.0.0", - "merge-descriptors": "1.0.3", - "methods": "~1.1.2", - "on-finished": "2.4.1", - "parseurl": "~1.3.3", - "path-to-regexp": "0.1.10", - "proxy-addr": "~2.0.7", - "qs": "6.13.0", - "range-parser": "~1.2.1", - "safe-buffer": "5.2.1", - "send": "0.19.0", - "serve-static": "1.16.2", - "setprototypeof": "1.2.0", - "statuses": "2.0.1", - "type-is": "~1.6.18", - "utils-merge": "1.0.1", - "vary": "~1.1.2" - }, - "engines": { - "node": ">= 0.10.0" - } - }, - "node_modules/express-body-parser-error-handler": { - "version": "1.0.7", - "resolved": "https://registry.npmjs.org/express-body-parser-error-handler/-/express-body-parser-error-handler-1.0.7.tgz", - "integrity": "sha512-QNhHyCbFFFI/SqMMb9P/p7jF0muIziXkOqe6VVXNGRbK3fxRa9qOX5qAcwLv7xa4rg70h5KahDuok0xsqqsKMw==", - "dev": true, - "dependencies": { - "@types/express": "^4.17.15" - } - }, "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -2027,28 +1618,10 @@ "node": "^10.12.0 || >=12.0.0" } }, - "node_modules/finalhandler": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.3.1.tgz", - "integrity": "sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ==", - "dev": true, - "dependencies": { - "debug": "2.6.9", - "encodeurl": "~2.0.0", - "escape-html": "~1.0.3", - "on-finished": "2.4.1", - "parseurl": "~1.3.3", - "statuses": "2.0.1", - "unpipe": "~1.0.0" - }, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/find-up": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", + "node_modules/find-up": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", + "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", "dev": true, "dependencies": { "locate-path": "^6.0.0", @@ -2104,29 +1677,12 @@ "node": ">= 6" } }, - "node_modules/forwarded": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", - "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/fresh": { - "version": "0.5.2", - "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", - "integrity": "sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, "node_modules/from": { "version": "0.1.7", "resolved": "https://registry.npmjs.org/from/-/from-0.1.7.tgz", "integrity": "sha512-twe20eF1OxVxp/ML/kq2p1uc6KvFK/+vs8WjEbeKmV2He22MKm7YF2ANIt+EOqhJ5L3K/SuuPhk0hWQDjOM23g==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/fs.realpath": { "version": "1.0.0", @@ -2184,15 +1740,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "dev": true, - "engines": { - "node": "6.* || 8.* || >= 10.*" - } - }, "node_modules/get-intrinsic": { "version": "1.2.4", "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz", @@ -2448,6 +1995,7 @@ "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.0.tgz", "integrity": "sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==", "dev": true, + "license": "MIT", "dependencies": { "depd": "2.0.0", "inherits": "2.0.4", @@ -2484,34 +2032,12 @@ "node": ">= 14" } }, - "node_modules/http-proxy-agent/node_modules/debug": { - "version": "4.3.5", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.5.tgz", - "integrity": "sha512-pt0bNEmneDIvdL1Xsd9oDQ/wrQRkXDT4AUWlNZNPKvW5x/jyO9VFXkJUP07vQ2upmw5PlaITaPKc31jK13V+jg==", - "dev": true, - "dependencies": { - "ms": "2.1.2" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, - "node_modules/http-proxy-agent/node_modules/ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, "node_modules/https-proxy-agent": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz", "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==", "dev": true, + "license": "MIT", "dependencies": { "agent-base": "6", "debug": "4" @@ -2520,29 +2046,6 @@ "node": ">= 6" } }, - "node_modules/https-proxy-agent/node_modules/debug": { - "version": "4.3.4", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", - "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "dev": true, - "dependencies": { - "ms": "2.1.2" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, - "node_modules/https-proxy-agent/node_modules/ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, "node_modules/husky": { "version": "9.0.11", "resolved": "https://registry.npmjs.org/husky/-/husky-9.0.11.tgz", @@ -2559,12 +2062,13 @@ } }, "node_modules/iconv-lite": { - "version": "0.4.24", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", - "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", "dev": true, + "license": "MIT", "dependencies": { - "safer-buffer": ">= 2.1.2 < 3" + "safer-buffer": ">= 2.1.2 < 3.0.0" }, "engines": { "node": ">=0.10.0" @@ -2583,7 +2087,8 @@ "version": "3.0.6", "resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz", "integrity": "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/import-fresh": { "version": "3.3.0", @@ -2647,15 +2152,6 @@ "node": ">= 0.4" } }, - "node_modules/ipaddr.js": { - "version": "1.9.1", - "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", - "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==", - "dev": true, - "engines": { - "node": ">= 0.10" - } - }, "node_modules/is-array-buffer": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.4.tgz", @@ -2763,15 +2259,6 @@ "node": ">=0.10.0" } }, - "node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "engines": { - "node": ">=8" - } - }, "node_modules/is-glob": { "version": "4.0.3", "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", @@ -2846,7 +2333,8 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-running/-/is-running-2.1.0.tgz", "integrity": "sha512-mjJd3PujZMl7j+D395WTIO5tU5RIDBfVSRtRR4VOJou3H66E38UjbjvDGh3slJzPuolsb+yQFqwHNNdyp5jg3w==", - "dev": true + "dev": true, + "license": "BSD" }, "node_modules/is-shared-array-buffer": { "version": "1.0.3", @@ -2938,6 +2426,116 @@ "integrity": "sha512-m4avr8yL8kmFN8psrbFFFmB/If14iN5o9nw/NgnnM+kybDJpRsAynV2BsfpTYrTRysYUdADVD7CkUUizgkpLfg==", "dev": true }, + "node_modules/jquery-test-runner": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/jquery-test-runner/-/jquery-test-runner-0.2.1.tgz", + "integrity": "sha512-NNqRAEgb0GSW8Pwk9msCGTzHD14ROrGZde/Gnm/F6sTysQifHAGn8fbbxXkXQIu+AyYBNzzSb7e6Rt9KL5WJgg==", + "dev": true, + "license": "MIT", + "dependencies": { + "browserstack-local": "^1.5.6", + "chalk": "^5.4.1", + "commander": "^13.0.0", + "diff": "^7.0.0", + "exit-hook": "^4.0.0", + "jsdom": "^25.0.1", + "raw-body": "^3.0.0", + "selenium-webdriver": "^4.27.0", + "yaml": "^2.6.1" + }, + "bin": { + "jquery-test-runner": "bin/command.js", + "jtr": "bin/command.js" + } + }, + "node_modules/jquery-test-runner/node_modules/agent-base": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.3.tgz", + "integrity": "sha512-jRR5wdylq8CkOe6hei19GGZnxM6rBGwFl3Bg0YItGDimvjGtAvdZk4Pu6Cl4u4Igsws4a1fd1Vq3ezrhn4KmFw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 14" + } + }, + "node_modules/jquery-test-runner/node_modules/commander": { + "version": "13.0.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-13.0.0.tgz", + "integrity": "sha512-oPYleIY8wmTVzkvQq10AEok6YcTC4sRUBl8F9gVuwchGVUCTbl/vhLTaQqutuuySYOsu8YTgV+OxKc/8Yvx+mQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/jquery-test-runner/node_modules/https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.2", + "debug": "4" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/jquery-test-runner/node_modules/jsdom": { + "version": "25.0.1", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-25.0.1.tgz", + "integrity": "sha512-8i7LzZj7BF8uplX+ZyOlIz86V6TAsSs+np6m1kpW9u0JWi4z/1t+FzcK1aek+ybTnAC4KhBL4uXCNT0wcUIeCw==", + "dev": true, + "license": "MIT", + "dependencies": { + "cssstyle": "^4.1.0", + "data-urls": "^5.0.0", + "decimal.js": "^10.4.3", + "form-data": "^4.0.0", + "html-encoding-sniffer": "^4.0.0", + "http-proxy-agent": "^7.0.2", + "https-proxy-agent": "^7.0.5", + "is-potential-custom-element-name": "^1.0.1", + "nwsapi": "^2.2.12", + "parse5": "^7.1.2", + "rrweb-cssom": "^0.7.1", + "saxes": "^6.0.0", + "symbol-tree": "^3.2.4", + "tough-cookie": "^5.0.0", + "w3c-xmlserializer": "^5.0.0", + "webidl-conversions": "^7.0.0", + "whatwg-encoding": "^3.1.1", + "whatwg-mimetype": "^4.0.0", + "whatwg-url": "^14.0.0", + "ws": "^8.18.0", + "xml-name-validator": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "peerDependencies": { + "canvas": "^2.11.2" + }, + "peerDependenciesMeta": { + "canvas": { + "optional": true + } + } + }, + "node_modules/jquery-test-runner/node_modules/tough-cookie": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.0.0.tgz", + "integrity": "sha512-FRKsF7cz96xIIeMZ82ehjC3xW2E+O2+v11udrDYewUbszngYhsGa8z6YUMMzO9QJZzzyd0nGGXnML/TReX6W8Q==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "tldts": "^6.1.32" + }, + "engines": { + "node": ">=16" + } + }, "node_modules/js-yaml": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", @@ -3002,23 +2600,6 @@ "node": ">= 14" } }, - "node_modules/jsdom/node_modules/debug": { - "version": "4.3.5", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.5.tgz", - "integrity": "sha512-pt0bNEmneDIvdL1Xsd9oDQ/wrQRkXDT4AUWlNZNPKvW5x/jyO9VFXkJUP07vQ2upmw5PlaITaPKc31jK13V+jg==", - "dev": true, - "dependencies": { - "ms": "2.1.2" - }, - "engines": { - "node": ">=6.0" - }, - "peerDependenciesMeta": { - "supports-color": { - "optional": true - } - } - }, "node_modules/jsdom/node_modules/https-proxy-agent": { "version": "7.0.5", "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.5.tgz", @@ -3032,12 +2613,6 @@ "node": ">= 14" } }, - "node_modules/jsdom/node_modules/ms": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", - "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", - "dev": true - }, "node_modules/json-buffer": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", @@ -3073,6 +2648,7 @@ "resolved": "https://registry.npmjs.org/jszip/-/jszip-3.10.1.tgz", "integrity": "sha512-xXDvecyTpGLrqFrvkrUSoxxfJI5AH7U8zxxtVclpsUtMCq4JQ290LY8AW5c7Ggnr/Y/oK+bQMbqK2qmtk3pN4g==", "dev": true, + "license": "(MIT OR GPL-3.0-or-later)", "dependencies": { "lie": "~3.3.0", "pako": "~1.0.2", @@ -3114,6 +2690,7 @@ "resolved": "https://registry.npmjs.org/lie/-/lie-3.3.0.tgz", "integrity": "sha512-UaiMJzeWRlEujzAuw5LokY1L5ecNQYZKfmyZ9L7wDHb/p5etKaxXhohBcrw0EYby+G/NA52vRSN4N39dxHAIwQ==", "dev": true, + "license": "MIT", "dependencies": { "immediate": "~3.0.5" } @@ -3159,45 +2736,6 @@ "integrity": "sha512-CkYQrPYZfWnu/DAmVCpTSX/xHpKZ80eKh2lAkyA6AJTef6bW+6JpbQZN5rofum7da+SyN1bi5ctTm+lTfcCW3g==", "dev": true }, - "node_modules/media-typer": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", - "integrity": "sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/merge-descriptors": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.3.tgz", - "integrity": "sha512-gaNvAS7TZ897/rVaZ0nMtAyxNyi/pdbjbAwUpFQpN70GqnVfOiXpeUUMKRBmzXaSQ8DdTX4/0ms62r2K+hE6mQ==", - "dev": true, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/methods": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", - "integrity": "sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/mime": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", - "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==", - "dev": true, - "bin": { - "mime": "cli.js" - }, - "engines": { - "node": ">=4" - } - }, "node_modules/mime-db": { "version": "1.52.0", "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", @@ -3241,10 +2779,11 @@ } }, "node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "dev": true + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true, + "license": "MIT" }, "node_modules/native-promise-only": { "version": "0.8.1", @@ -3258,15 +2797,6 @@ "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", "dev": true }, - "node_modules/negotiator": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", - "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, "node_modules/nise": { "version": "1.5.3", "resolved": "https://registry.npmjs.org/nise/-/nise-1.5.3.tgz", @@ -3408,18 +2938,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/on-finished": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.1.tgz", - "integrity": "sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg==", - "dev": true, - "dependencies": { - "ee-first": "1.1.1" - }, - "engines": { - "node": ">= 0.8" - } - }, "node_modules/once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -3480,7 +2998,8 @@ "version": "1.0.11", "resolved": "https://registry.npmjs.org/pako/-/pako-1.0.11.tgz", "integrity": "sha512-4hLB8Py4zZce5s4yd9XzopqwVv/yGNhV1Bl8NTmCq1763HeK2+EwVTv+leGeL13Dnh2wfbqowVPXCIO0z4taYw==", - "dev": true + "dev": true, + "license": "(MIT AND Zlib)" }, "node_modules/parent-module": { "version": "1.0.1", @@ -3506,15 +3025,6 @@ "url": "https://github.com/inikulin/parse5?sponsor=1" } }, - "node_modules/parseurl": { - "version": "1.3.3", - "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", - "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", - "dev": true, - "engines": { - "node": ">= 0.8" - } - }, "node_modules/path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -3548,17 +3058,15 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", "dev": true }, - "node_modules/path-to-regexp": { - "version": "0.1.10", - "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.10.tgz", - "integrity": "sha512-7lf7qcQidTku0Gu3YDPc8DJ1q7OOucfa/BSsIwjuh56VU7katFvuM8hULfkwB3Fns/rsVF7PwPKVw1sl5KQS9w==", - "dev": true - }, "node_modules/pause-stream": { "version": "0.0.11", "resolved": "https://registry.npmjs.org/pause-stream/-/pause-stream-0.0.11.tgz", "integrity": "sha512-e3FBlXLmN/D1S+zHzanP4E/4Z60oFAa3O051qt1pxa7DEJWKAyil6upYVXCWadEnuoqa4Pkc9oUx9zsxYeRv8A==", "dev": true, + "license": [ + "MIT", + "Apache2" + ], "dependencies": { "through": "~2.3" } @@ -3585,26 +3093,15 @@ "version": "2.0.1", "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", - "dev": true - }, - "node_modules/proxy-addr": { - "version": "2.0.7", - "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", - "integrity": "sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==", "dev": true, - "dependencies": { - "forwarded": "0.2.0", - "ipaddr.js": "1.9.1" - }, - "engines": { - "node": ">= 0.10" - } + "license": "MIT" }, "node_modules/ps-tree": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/ps-tree/-/ps-tree-1.2.0.tgz", "integrity": "sha512-0VnamPPYHl4uaU/nSFeZZpR21QAWRz+sRv4iW9+v/GS/J5U5iZB5BNN6J0RMoOvdx2gWM2+ZFMIm58q24e4UYA==", "dev": true, + "license": "MIT", "dependencies": { "event-stream": "=3.3.4" }, @@ -3630,21 +3127,6 @@ "node": ">=6" } }, - "node_modules/qs": { - "version": "6.13.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", - "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", - "dev": true, - "dependencies": { - "side-channel": "^1.0.6" - }, - "engines": { - "node": ">=0.6" - }, - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/querystringify": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", @@ -3688,24 +3170,16 @@ "node": ">=10" } }, - "node_modules/range-parser": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", - "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", - "dev": true, - "engines": { - "node": ">= 0.6" - } - }, "node_modules/raw-body": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", - "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-3.0.0.tgz", + "integrity": "sha512-RmkhL8CAyCRPXCE28MMH0z2PNWQBNk2Q09ZdxM9IOOXwxwZbN+qbWaatPkdkWIKL2ZVDImrN/pK5HTRz2PcS4g==", "dev": true, + "license": "MIT", "dependencies": { "bytes": "3.1.2", "http-errors": "2.0.0", - "iconv-lite": "0.4.24", + "iconv-lite": "0.6.3", "unpipe": "1.0.0" }, "engines": { @@ -3717,6 +3191,7 @@ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", "dev": true, + "license": "MIT", "dependencies": { "core-util-is": "~1.0.0", "inherits": "~2.0.3", @@ -3731,13 +3206,8 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==", - "dev": true - }, - "node_modules/readable-stream/node_modules/safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/regexp.prototype.flags": { "version": "1.5.2", @@ -3757,15 +3227,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/requires-port": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", @@ -3907,24 +3368,11 @@ } }, "node_modules/safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ] + "license": "MIT" }, "node_modules/safe-regex-test": { "version": "1.0.3", @@ -3962,14 +3410,26 @@ } }, "node_modules/selenium-webdriver": { - "version": "4.21.0", - "resolved": "https://registry.npmjs.org/selenium-webdriver/-/selenium-webdriver-4.21.0.tgz", - "integrity": "sha512-WaEJHZjOWNth1QG5FEpxpREER0qptZBMonFU6GtAqdCNLJVxbtC3E7oS/I/+Q1sf1W032Wg0Ebk+m46lANOXyQ==", + "version": "4.27.0", + "resolved": "https://registry.npmjs.org/selenium-webdriver/-/selenium-webdriver-4.27.0.tgz", + "integrity": "sha512-LkTJrNz5socxpPnWPODQ2bQ65eYx9JK+DQMYNihpTjMCqHwgWGYQnQTCAAche2W3ZP87alA+1zYPvgS8tHNzMQ==", "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/SeleniumHQ" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/selenium" + } + ], + "license": "Apache-2.0", "dependencies": { + "@bazel/runfiles": "^6.3.1", "jszip": "^3.10.1", "tmp": "^0.2.3", - "ws": ">=8.16.0" + "ws": "^8.18.0" }, "engines": { "node": ">= 14.21.0" @@ -3984,60 +3444,6 @@ "semver": "bin/semver" } }, - "node_modules/send": { - "version": "0.19.0", - "resolved": "https://registry.npmjs.org/send/-/send-0.19.0.tgz", - "integrity": "sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==", - "dev": true, - "dependencies": { - "debug": "2.6.9", - "depd": "2.0.0", - "destroy": "1.2.0", - "encodeurl": "~1.0.2", - "escape-html": "~1.0.3", - "etag": "~1.8.1", - "fresh": "0.5.2", - "http-errors": "2.0.0", - "mime": "1.6.0", - "ms": "2.1.3", - "on-finished": "2.4.1", - "range-parser": "~1.2.1", - "statuses": "2.0.1" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/send/node_modules/encodeurl": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", - "integrity": "sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==", - "dev": true, - "engines": { - "node": ">= 0.8" - } - }, - "node_modules/send/node_modules/ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "dev": true - }, - "node_modules/serve-static": { - "version": "1.16.2", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.16.2.tgz", - "integrity": "sha512-VqpjJZKadQB/PEbEwvFdO43Ax5dFBZ2UECszz8bQ7pi7wt//PWe1P6MN7eCnjsatYtBT6EuiClbjSWP2WrIoTw==", - "dev": true, - "dependencies": { - "encodeurl": "~2.0.0", - "escape-html": "~1.0.3", - "parseurl": "~1.3.3", - "send": "0.19.0" - }, - "engines": { - "node": ">= 0.8.0" - } - }, "node_modules/set-function-length": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", @@ -4074,13 +3480,15 @@ "version": "1.0.5", "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", "integrity": "sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/setprototypeof": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", - "dev": true + "dev": true, + "license": "ISC" }, "node_modules/shebang-command": { "version": "2.0.0", @@ -4182,6 +3590,7 @@ "resolved": "https://registry.npmjs.org/split/-/split-0.3.3.tgz", "integrity": "sha512-wD2AeVmxXRBoX44wAycgjVpMhvbwdI2aZjCkvfNcH1YqHQvJVa1duWc73OyVGJUc05fhFaTZeQ/PYsrmyH0JVA==", "dev": true, + "license": "MIT", "dependencies": { "through": "2" }, @@ -4194,6 +3603,7 @@ "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", "integrity": "sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.8" } @@ -4203,6 +3613,7 @@ "resolved": "https://registry.npmjs.org/stream-combiner/-/stream-combiner-0.0.4.tgz", "integrity": "sha512-rT00SPnTVyRsaSz5zgSPma/aHSOic5U1prhYdRy5HS2kTZviFpmDgzilbtsJsxiroqACmayynDN/9VzIbX5DOw==", "dev": true, + "license": "MIT", "dependencies": { "duplexer": "~0.1.1" } @@ -4212,30 +3623,11 @@ "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "dev": true, + "license": "MIT", "dependencies": { "safe-buffer": "~5.1.0" } }, - "node_modules/string_decoder/node_modules/safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", - "dev": true - }, - "node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/string.prototype.trim": { "version": "1.2.9", "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.9.tgz", @@ -4350,6 +3742,7 @@ "resolved": "https://registry.npmjs.org/temp-fs/-/temp-fs-0.9.9.tgz", "integrity": "sha512-WfecDCR1xC9b0nsrzSaxPf3ZuWeWLUWblW4vlDQAa1biQaKHiImHnJfeQocQe/hXKMcolRzgkcVX/7kK4zoWbw==", "dev": true, + "license": "MIT", "dependencies": { "rimraf": "~2.5.2" }, @@ -4363,6 +3756,7 @@ "integrity": "sha512-Lw7SHMjssciQb/rRz7JyPIy9+bbUshEucPoLRvWqy09vC5zQixl8Uet+Zl+SROBB/JMWHJRdCk1qdxNWHNMvlQ==", "deprecated": "Rimraf versions prior to v4 are no longer supported", "dev": true, + "license": "ISC", "dependencies": { "glob": "^7.0.5" }, @@ -4380,7 +3774,8 @@ "version": "2.3.8", "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==", - "dev": true + "dev": true, + "license": "MIT" }, "node_modules/tiny-glob": { "version": "0.2.9", @@ -4392,11 +3787,32 @@ "globrex": "^0.1.2" } }, + "node_modules/tldts": { + "version": "6.1.70", + "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.70.tgz", + "integrity": "sha512-/W1YVgYVJd9ZDjey5NXadNh0mJXkiUMUue9Zebd0vpdo1sU+H4zFFTaJ1RKD4N6KFoHfcXy6l+Vu7bh+bdWCzA==", + "dev": true, + "license": "MIT", + "dependencies": { + "tldts-core": "^6.1.70" + }, + "bin": { + "tldts": "bin/cli.js" + } + }, + "node_modules/tldts-core": { + "version": "6.1.70", + "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.70.tgz", + "integrity": "sha512-RNnIXDB1FD4T9cpQRErEqw6ZpjLlGdMOitdV+0xtbsnwr4YFka1zpc7D4KD+aAn8oSG5JyFrdasZTE04qDE9Yg==", + "dev": true, + "license": "MIT" + }, "node_modules/tmp": { "version": "0.2.3", "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.2.3.tgz", "integrity": "sha512-nZD7m9iCPC5g0pYmcaxogYKggSfLsdxl8of3Q/oIbqCqLLIO9IAF0GWjX1z9NZRHPiXv8Wex4yDCaZsgEw0Y8w==", "dev": true, + "license": "MIT", "engines": { "node": ">=14.14" } @@ -4406,6 +3822,7 @@ "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", "dev": true, + "license": "MIT", "engines": { "node": ">=0.6" } @@ -4483,19 +3900,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/type-is": { - "version": "1.6.18", - "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", - "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==", - "dev": true, - "dependencies": { - "media-typer": "0.3.0", - "mime-types": "~2.1.24" - }, - "engines": { - "node": ">= 0.6" - } - }, "node_modules/typed-array-buffer": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.2.tgz", @@ -4605,12 +4009,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/undici-types": { - "version": "5.26.5", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz", - "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==", - "dev": true - }, "node_modules/universalify": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.2.0.tgz", @@ -4625,6 +4023,7 @@ "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", "dev": true, + "license": "MIT", "engines": { "node": ">= 0.8" } @@ -4652,25 +4051,8 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", - "dev": true - }, - "node_modules/utils-merge": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", - "integrity": "sha512-pMZTvIkT1d+TFGvDOqodOclx0QWkkgi6Tdoa8gC8ffGAAqz9pzPTZWAybbsHHoED/ztMtkv/VoYTYyShUn81hA==", "dev": true, - "engines": { - "node": ">= 0.4.0" - } - }, - "node_modules/vary": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", - "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", - "dev": true, - "engines": { - "node": ">= 0.8" - } + "license": "MIT" }, "node_modules/w3c-xmlserializer": { "version": "5.0.0", @@ -4705,18 +4087,6 @@ "node": ">=18" } }, - "node_modules/whatwg-encoding/node_modules/iconv-lite": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", - "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", - "dev": true, - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/whatwg-mimetype": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", @@ -4798,23 +4168,6 @@ "node": ">=0.10.0" } }, - "node_modules/wrap-ansi": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, "node_modules/wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", @@ -4822,10 +4175,11 @@ "dev": true }, "node_modules/ws": { - "version": "8.17.1", - "resolved": "https://registry.npmjs.org/ws/-/ws-8.17.1.tgz", - "integrity": "sha512-6XQFvXTkbfUOZOKKILFG1PDK2NDQs4azKQl26T0YS5CxqWLgXajbPZ+h4gZekJyRqFU8pvnbAbbs/3TgRPy+GQ==", + "version": "8.18.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.18.0.tgz", + "integrity": "sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw==", "dev": true, + "license": "MIT", "engines": { "node": ">=10.0.0" }, @@ -4857,40 +4211,17 @@ "integrity": "sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==", "dev": true }, - "node_modules/y18n": { - "version": "5.0.8", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", - "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", + "node_modules/yaml": { + "version": "2.6.1", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.6.1.tgz", + "integrity": "sha512-7r0XPzioN/Q9kXBro/XPnA6kznR73DHq+GXh5ON7ZozRO6aMjbmiBuKste2wslTFkC5d1dw0GooOCepZXJ2SAg==", "dev": true, - "engines": { - "node": ">=10" - } - }, - "node_modules/yargs": { - "version": "17.7.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", - "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", - "dev": true, - "dependencies": { - "cliui": "^8.0.1", - "escalade": "^3.1.1", - "get-caller-file": "^2.0.5", - "require-directory": "^2.1.1", - "string-width": "^4.2.3", - "y18n": "^5.0.5", - "yargs-parser": "^21.1.1" + "license": "ISC", + "bin": { + "yaml": "bin.mjs" }, "engines": { - "node": ">=12" - } - }, - "node_modules/yargs-parser": { - "version": "21.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", - "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", - "dev": true, - "engines": { - "node": ">=12" + "node": ">= 14" } }, "node_modules/yocto-queue": { diff --git a/package.json b/package.json index f12e695f..c52a71ce 100644 --- a/package.json +++ b/package.json @@ -25,42 +25,34 @@ "prepare": "husky", "pretest": "npm run npmcopy && npm run build && npm run lint", "start": "npm run npmcopy && node build/tasks/build-watch.js", - "test:browser": "npm run pretest && npm run test:unit -- -b chrome -b firefox -h", + "test:browser": "npm run pretest && npm run test:unit -- -b chrome -b firefox --headless", "test:ie": "npm run pretest && npm run test:unit -- -v -b ie", "test:node_smoke_tests": "npm run pretest && node test/node_smoke_tests/smoke_tests.cjs", "test:safari": "npm run pretest && npm run test:unit -- -v -b safari", - "test:server": "node test/runner/server.js", - "test:unit": "node test/runner/command.js", + "test:server": "jtr serve", + "test:unit": "jtr", "test": "npm run test:node_smoke_tests && npm run test:browser" }, "peerDependencies": { "jquery": ">=3 <4" }, "devDependencies": { - "@types/selenium-webdriver": "4.1.22", - "body-parser": "1.20.3", - "browserstack-local": "1.5.5", - "chalk": "5.3.0", + "chalk": "5.4.1", "commitplease": "3.2.0", - "diff": "5.2.0", "enquirer": "2.4.1", "eslint": "8.57.0", "eslint-config-jquery": "3.0.2", "eslint-plugin-import": "2.29.1", - "exit-hook": "4.0.0", - "express": "4.21.1", - "express-body-parser-error-handler": "1.0.7", "globals": "15.3.0", "husky": "9.0.11", "jquery": "3.7.1", + "jquery-test-runner": "0.2.1", "jsdom": "24.1.0", "native-promise-only": "0.8.1", "qunit": "2.21.0", "rollup": "4.22.4", - "selenium-webdriver": "4.21.0", "sinon": "7.5.0", - "uglify-js": "3.9.4", - "yargs": "17.7.2" + "uglify-js": "3.9.4" }, "keywords": [ "jquery", diff --git a/test/data/testinit.js b/test/data/testinit.js index 61414f68..54ea2686 100644 --- a/test/data/testinit.js +++ b/test/data/testinit.js @@ -244,8 +244,6 @@ TestManager.init( { "jquery": { urlTag: "jquery", - - // Keep in sync with test/runner/jquery.js choices: [ "dev", "min", @@ -277,8 +275,6 @@ TestManager.init( { }, "jquery-migrate": { urlTag: "plugin", - - // Keep in sync with test/runner/jquery-migrate.js choices: [ "dev", "min", diff --git a/test/runner/browsers.js b/test/runner/browsers.js deleted file mode 100644 index e78f2d8e..00000000 --- a/test/runner/browsers.js +++ /dev/null @@ -1,242 +0,0 @@ -import chalk from "chalk"; -import { getBrowserString } from "./lib/getBrowserString.js"; -import { - createWorker, - deleteWorker, - getAvailableSessions -} from "./browserstack/api.js"; -import createDriver from "./selenium/createDriver.js"; - -const workers = Object.create( null ); - -/** - * Keys are browser strings - * Structure of a worker: - * { - * browser: object // The browser object - * debug: boolean // Stops the worker from being cleaned up when finished - * lastTouch: number // The last time a request was received - * restarts: number // The number of times the worker has been restarted - * options: object // The options to create the worker - * url: string // The URL the worker is on - * quit: function // A function to stop the worker - * } - */ - -// Acknowledge the worker within the time limit. -// BrowserStack can take much longer spinning up -// some browsers, such as iOS 15 Safari. -const ACKNOWLEDGE_INTERVAL = 1000; -const ACKNOWLEDGE_TIMEOUT = 60 * 1000 * 5; - -const MAX_WORKER_RESTARTS = 5; - -// No report after the time limit -// should refresh the worker -const RUN_WORKER_TIMEOUT = 60 * 1000 * 2; - -const WORKER_WAIT_TIME = 30000; - -// Limit concurrency to 8 by default in selenium -const MAX_SELENIUM_CONCURRENCY = 8; - -export async function createBrowserWorker( url, browser, options, restarts = 0 ) { - if ( restarts > MAX_WORKER_RESTARTS ) { - throw new Error( - `Reached the maximum number of restarts for ${ chalk.yellow( - getBrowserString( browser ) - ) }` - ); - } - const { browserstack, debug, headless, runId, tunnelId, verbose } = options; - while ( await maxWorkersReached( options ) ) { - if ( verbose ) { - console.log( "\nWaiting for available sessions..." ); - } - await new Promise( ( resolve ) => setTimeout( resolve, WORKER_WAIT_TIME ) ); - } - - const fullBrowser = getBrowserString( browser ); - - let worker; - - if ( browserstack ) { - worker = await createWorker( { - ...browser, - url: encodeURI( url ), - project: "jquery-migrate", - build: `Run ${ runId }`, - - // This is the maximum timeout allowed - // by BrowserStack. We do this because - // we control the timeout in the runner. - // See https://github.com/browserstack/api/blob/b324a6a5bc1b6052510d74e286b8e1c758c308a7/README.md#timeout300 - timeout: 1800, - - // Not documented in the API docs, - // but required to make local testing work. - // See https://www.browserstack.com/docs/automate/selenium/manage-multiple-connections#nodejs - "browserstack.local": true, - "browserstack.localIdentifier": tunnelId - } ); - worker.quit = () => deleteWorker( worker.id ); - } else { - const driver = await createDriver( { - browserName: browser.browser, - headless, - url, - verbose - } ); - worker = { - quit: () => driver.quit() - }; - } - - worker.debug = !!debug; - worker.url = url; - worker.browser = browser; - worker.restarts = restarts; - worker.options = options; - touchBrowser( browser ); - workers[ fullBrowser ] = worker; - - // Wait for the worker to show up in the list - // before returning it. - return ensureAcknowledged( worker ); -} - -export function touchBrowser( browser ) { - const fullBrowser = getBrowserString( browser ); - const worker = workers[ fullBrowser ]; - if ( worker ) { - worker.lastTouch = Date.now(); - } -} - -export async function setBrowserWorkerUrl( browser, url ) { - const fullBrowser = getBrowserString( browser ); - const worker = workers[ fullBrowser ]; - if ( worker ) { - worker.url = url; - } -} - -export async function restartBrowser( browser ) { - const fullBrowser = getBrowserString( browser ); - const worker = workers[ fullBrowser ]; - if ( worker ) { - await restartWorker( worker ); - } -} - -/** - * Checks that all browsers have received - * a response in the given amount of time. - * If not, the worker is restarted. - */ -export async function checkLastTouches() { - for ( const [ fullBrowser, worker ] of Object.entries( workers ) ) { - if ( Date.now() - worker.lastTouch > RUN_WORKER_TIMEOUT ) { - const options = worker.options; - if ( options.verbose ) { - console.log( - `\nNo response from ${ chalk.yellow( fullBrowser ) } in ${ - RUN_WORKER_TIMEOUT / 1000 / 60 - }min.` - ); - } - await restartWorker( worker ); - } - } -} - -export async function cleanupAllBrowsers( { verbose } ) { - const workersRemaining = Object.values( workers ); - const numRemaining = workersRemaining.length; - if ( numRemaining ) { - try { - await Promise.all( workersRemaining.map( ( worker ) => worker.quit() ) ); - if ( verbose ) { - console.log( - `Stopped ${ numRemaining } browser${ numRemaining > 1 ? "s" : "" }.` - ); - } - } catch ( error ) { - - // Log the error, but do not consider the test run failed - console.error( error ); - } - } -} - -async function maxWorkersReached( { - browserstack, - concurrency = MAX_SELENIUM_CONCURRENCY -} ) { - if ( browserstack ) { - return ( await getAvailableSessions() ) <= 0; - } - return workers.length >= concurrency; -} - -async function waitForAck( worker, { fullBrowser, verbose } ) { - delete worker.lastTouch; - return new Promise( ( resolve, reject ) => { - const interval = setInterval( () => { - if ( worker.lastTouch ) { - if ( verbose ) { - console.log( `\n${ fullBrowser } acknowledged.` ); - } - clearTimeout( timeout ); - clearInterval( interval ); - resolve(); - } - }, ACKNOWLEDGE_INTERVAL ); - - const timeout = setTimeout( () => { - clearInterval( interval ); - reject( - new Error( - `${ fullBrowser } not acknowledged after ${ - ACKNOWLEDGE_TIMEOUT / 1000 / 60 - }min.` - ) - ); - }, ACKNOWLEDGE_TIMEOUT ); - } ); -} - -async function ensureAcknowledged( worker ) { - const fullBrowser = getBrowserString( worker.browser ); - const verbose = worker.options.verbose; - try { - await waitForAck( worker, { fullBrowser, verbose } ); - return worker; - } catch ( error ) { - console.error( error.message ); - await restartWorker( worker ); - } -} - -async function cleanupWorker( worker, { verbose } ) { - for ( const [ fullBrowser, w ] of Object.entries( workers ) ) { - if ( w === worker ) { - delete workers[ fullBrowser ]; - await worker.quit(); - if ( verbose ) { - console.log( `\nStopped ${ fullBrowser }.` ); - } - return; - } - } -} - -async function restartWorker( worker ) { - await cleanupWorker( worker, worker.options ); - await createBrowserWorker( - worker.url, - worker.browser, - worker.options, - worker.restarts + 1 - ); -} diff --git a/test/runner/browserstack/api.js b/test/runner/browserstack/api.js deleted file mode 100644 index 632f90c3..00000000 --- a/test/runner/browserstack/api.js +++ /dev/null @@ -1,332 +0,0 @@ -/** - * Browserstack API is documented at - * https://github.com/browserstack/api - */ - -import { createAuthHeader } from "./createAuthHeader.js"; - -const browserstackApi = "https://api.browserstack.com"; -const apiVersion = 5; - -const username = process.env.BROWSERSTACK_USERNAME; -const accessKey = process.env.BROWSERSTACK_ACCESS_KEY; - -// iOS has null for version numbers, -// and we do not need a similar check for OS versions. -const rfinalVersion = /(?:^[0-9\.]+$)|(?:^null$)/; -const rlatest = /^latest-(\d+)$/; - -const rnonDigits = /(?:[^\d\.]+)|(?:20\d{2})/g; - -async function fetchAPI( path, options = {}, versioned = true ) { - if ( !username || !accessKey ) { - throw new Error( - "BROWSERSTACK_USERNAME and BROWSERSTACK_ACCESS_KEY environment variables must be set." - ); - } - const init = { - method: "GET", - ...options, - headers: { - authorization: createAuthHeader( username, accessKey ), - accept: "application/json", - "content-type": "application/json", - ...options.headers - } - }; - const response = await fetch( - `${ browserstackApi }/${ versioned ? `${ apiVersion }/` : "" }${ path }`, - init - ); - if ( !response.ok ) { - console.log( - `\n${ init.method } ${ path }`, - response.status, - response.statusText - ); - throw new Error( `Error fetching ${ path }` ); - } - return response.json(); -} - -/** - * ============================= - * Browsers API - * ============================= - */ - -function compareVersionNumbers( a, b ) { - if ( a != null && b == null ) { - return -1; - } - if ( a == null && b != null ) { - return 1; - } - if ( a == null && b == null ) { - return 0; - } - const aParts = a.replace( rnonDigits, "" ).split( "." ); - const bParts = b.replace( rnonDigits, "" ).split( "." ); - - if ( aParts.length > bParts.length ) { - return -1; - } - if ( aParts.length < bParts.length ) { - return 1; - } - - for ( let i = 0; i < aParts.length; i++ ) { - const aPart = Number( aParts[ i ] ); - const bPart = Number( bParts[ i ] ); - if ( aPart < bPart ) { - return -1; - } - if ( aPart > bPart ) { - return 1; - } - } - - if ( rnonDigits.test( a ) && !rnonDigits.test( b ) ) { - return -1; - } - if ( !rnonDigits.test( a ) && rnonDigits.test( b ) ) { - return 1; - } - - return 0; -} - -function sortBrowsers( a, b ) { - if ( a.browser < b.browser ) { - return -1; - } - if ( a.browser > b.browser ) { - return 1; - } - const browserComparison = compareVersionNumbers( - a.browser_version, - b.browser_version - ); - if ( browserComparison ) { - return browserComparison; - } - if ( a.os < b.os ) { - return -1; - } - if ( a.os > b.os ) { - return 1; - } - const osComparison = compareVersionNumbers( a.os_version, b.os_version ); - if ( osComparison ) { - return osComparison; - } - const deviceComparison = compareVersionNumbers( a.device, b.device ); - if ( deviceComparison ) { - return deviceComparison; - } - return 0; -} - -export async function getBrowsers( { flat = false } = {} ) { - const query = new URLSearchParams(); - if ( flat ) { - query.append( "flat", true ); - } - const browsers = await fetchAPI( `/browsers?${ query }` ); - return browsers.sort( sortBrowsers ); -} - -function matchVersion( browserVersion, version ) { - if ( !version ) { - return false; - } - const regex = new RegExp( - `^${ version.replace( /\\/g, "\\\\" ).replace( /\./g, "\\." ) }\\b`, - "i" - ); - return regex.test( browserVersion ); -} - -export async function filterBrowsers( filter ) { - const browsers = await getBrowsers( { flat: true } ); - if ( !filter ) { - return browsers; - } - const filterBrowser = ( filter.browser ?? "" ).toLowerCase(); - const filterVersion = ( filter.browser_version ?? "" ).toLowerCase(); - const filterOs = ( filter.os ?? "" ).toLowerCase(); - const filterOsVersion = ( filter.os_version ?? "" ).toLowerCase(); - const filterDevice = ( filter.device ?? "" ).toLowerCase(); - - const filteredWithoutVersion = browsers.filter( ( browser ) => { - return ( - ( !filterBrowser || filterBrowser === browser.browser.toLowerCase() ) && - ( !filterOs || filterOs === browser.os.toLowerCase() ) && - ( !filterOsVersion || matchVersion( browser.os_version, filterOsVersion ) ) && - ( !filterDevice || filterDevice === ( browser.device || "" ).toLowerCase() ) - ); - } ); - - if ( !filterVersion ) { - return filteredWithoutVersion; - } - - if ( filterVersion.startsWith( "latest" ) ) { - const groupedByName = filteredWithoutVersion - .filter( ( b ) => rfinalVersion.test( b.browser_version ) ) - .reduce( ( acc, browser ) => { - acc[ browser.browser ] = acc[ browser.browser ] ?? []; - acc[ browser.browser ].push( browser ); - return acc; - }, Object.create( null ) ); - - const filtered = []; - for ( const group of Object.values( groupedByName ) ) { - const latest = group[ group.length - 1 ]; - - // Mobile devices do not have browser version. - // Skip the version check for these, - // but include the latest in the list if it made it - // through filtering. - if ( !latest.browser_version ) { - - // Do not include in the list for latest-n. - if ( filterVersion === "latest" ) { - filtered.push( latest ); - } - continue; - } - - // Get the latest version and subtract the number from the filter, - // ignoring any patch versions, which may differ between major versions. - const num = rlatest.exec( filterVersion ); - const version = parseInt( latest.browser_version ) - ( num ? num[ 1 ] : 0 ); - const match = group.findLast( ( browser ) => { - return matchVersion( browser.browser_version, version.toString() ); - } ); - if ( match ) { - filtered.push( match ); - } - } - return filtered; - } - - return filteredWithoutVersion.filter( ( browser ) => { - return matchVersion( browser.browser_version, filterVersion ); - } ); -} - -export async function listBrowsers( filter ) { - const browsers = await filterBrowsers( filter ); - console.log( "Available browsers:" ); - for ( const browser of browsers ) { - let message = ` ${ browser.browser }_`; - if ( browser.device ) { - message += `:${ browser.device }_`; - } else { - message += `${ browser.browser_version }_`; - } - message += `${ browser.os }_${ browser.os_version }`; - console.log( message ); - } -} - -export async function getLatestBrowser( filter ) { - if ( !filter.browser_version ) { - filter.browser_version = "latest"; - } - const browsers = await filterBrowsers( filter ); - return browsers[ browsers.length - 1 ]; -} - -/** - * ============================= - * Workers API - * ============================= - */ - -/** - * A browser object may only have one of `browser` or `device` set; - * which property is set will depend on `os`. - * - * `options`: is an object with the following properties: - * `os`: The operating system. - * `os_version`: The operating system version. - * `browser`: The browser name. - * `browser_version`: The browser version. - * `device`: The device name. - * `url` (optional): Which URL to navigate to upon creation. - * `timeout` (optional): Maximum life of the worker (in seconds). Maximum value of `1800`. Specifying `0` will use the default of `300`. - * `name` (optional): Provide a name for the worker. - * `build` (optional): Group workers into a build. - * `project` (optional): Provide the project the worker belongs to. - * `resolution` (optional): Specify the screen resolution (e.g. "1024x768"). - * `browserstack.local` (optional): Set to `true` to mark as local testing. - * `browserstack.video` (optional): Set to `false` to disable video recording. - * `browserstack.localIdentifier` (optional): ID of the local tunnel. - */ -export function createWorker( options ) { - return fetchAPI( "/worker", { - method: "POST", - body: JSON.stringify( options ) - } ); -} - -/** - * Returns a worker object, if one exists, with the following properties: - * `id`: The worker id. - * `status`: A string representing the current status of the worker. - * Possible statuses: `"running"`, `"queue"`. - */ -export function getWorker( id ) { - return fetchAPI( `/worker/${ id }` ); -} - -export async function deleteWorker( id ) { - return fetchAPI( `/worker/${ id }`, { method: "DELETE" } ); -} - -export function getWorkers() { - return fetchAPI( "/workers" ); -} - -/** - * Stop all workers - */ -export async function stopWorkers() { - const workers = await getWorkers(); - - // Run each request on its own - // to avoid connect timeout errors. - console.log( `${ workers.length } workers running...` ); - for ( const worker of workers ) { - try { - await deleteWorker( worker.id ); - } catch ( error ) { - - // Log the error, but continue trying to remove workers. - console.error( error ); - } - } - console.log( "All workers stopped." ); -} - -/** - * ============================= - * Plan API - * ============================= - */ - -export function getPlan() { - return fetchAPI( "/automate/plan.json", {}, false ); -} - -export async function getAvailableSessions() { - try { - const [ plan, workers ] = await Promise.all( [ getPlan(), getWorkers() ] ); - return plan.parallel_sessions_max_allowed - workers.length; - } catch ( error ) { - console.error( error ); - return 0; - } -} diff --git a/test/runner/browserstack/buildBrowserFromString.js b/test/runner/browserstack/buildBrowserFromString.js deleted file mode 100644 index e0d99a03..00000000 --- a/test/runner/browserstack/buildBrowserFromString.js +++ /dev/null @@ -1,20 +0,0 @@ -export function buildBrowserFromString( str ) { - const [ browser, versionOrDevice, os, osVersion ] = str.split( "_" ); - - // If the version starts with a colon, it's a device - if ( versionOrDevice && versionOrDevice.startsWith( ":" ) ) { - return { - browser, - device: versionOrDevice.slice( 1 ), - os, - os_version: osVersion - }; - } - - return { - browser, - browser_version: versionOrDevice, - os, - os_version: osVersion - }; -} diff --git a/test/runner/browserstack/createAuthHeader.js b/test/runner/browserstack/createAuthHeader.js deleted file mode 100644 index fe4831e9..00000000 --- a/test/runner/browserstack/createAuthHeader.js +++ /dev/null @@ -1,7 +0,0 @@ -const textEncoder = new TextEncoder(); - -export function createAuthHeader( username, accessKey ) { - const encoded = textEncoder.encode( `${ username }:${ accessKey }` ); - const base64 = btoa( String.fromCodePoint.apply( null, encoded ) ); - return `Basic ${ base64 }`; -} diff --git a/test/runner/browserstack/local.js b/test/runner/browserstack/local.js deleted file mode 100644 index c84cf155..00000000 --- a/test/runner/browserstack/local.js +++ /dev/null @@ -1,34 +0,0 @@ -import browserstackLocal from "browserstack-local"; - -export async function localTunnel( localIdentifier, opts = {} ) { - const tunnel = new browserstackLocal.Local(); - - return new Promise( ( resolve, reject ) => { - - // https://www.browserstack.com/docs/local-testing/binary-params - tunnel.start( - { - "enable-logging-for-api": "", - localIdentifier, - ...opts - }, - async( error ) => { - if ( error || !tunnel.isRunning() ) { - return reject( error ); - } - resolve( { - stop: function stopTunnel() { - return new Promise( ( resolve, reject ) => { - tunnel.stop( ( error ) => { - if ( error ) { - return reject( error ); - } - resolve(); - } ); - } ); - } - } ); - } - ); - } ); -} diff --git a/test/runner/command.js b/test/runner/command.js deleted file mode 100644 index 462dba6e..00000000 --- a/test/runner/command.js +++ /dev/null @@ -1,143 +0,0 @@ -import yargs from "yargs/yargs"; -import { browsers } from "./flags/browsers.js"; -import { getPlan, listBrowsers, stopWorkers } from "./browserstack/api.js"; -import { buildBrowserFromString } from "./browserstack/buildBrowserFromString.js"; -import { modules } from "./flags/modules.js"; -import { run } from "./run.js"; -import { jqueryMigrate } from "./flags/jquery-migrate.js"; -import { jquery } from "./flags/jquery.js"; - -const argv = yargs( process.argv.slice( 2 ) ) - .version( false ) - .strict() - .command( { - command: "[options]", - describe: "Run jQuery Migrate tests in a browser" - } ) - .option( "jquery-migrate", { - type: "array", - choices: jqueryMigrate, - description: "Versions of jQuery Migrate to test." + - "Defaults to the minified version in the dist/ folder.", - default: [ "min" ] - } ) - .option( "jquery", { - type: "array", - choices: jquery, - description: "Versions of jQuery to test.", - default: [ "3.x-git.min" ] - } ) - .option( "module", { - alias: "m", - type: "array", - choices: modules, - description: - "Run tests for a specific module. " + - "Pass multiple modules by repeating the option. " + - "Defaults to all modules." - } ) - .option( "browser", { - alias: "b", - type: "array", - choices: browsers, - description: - "Run tests in a specific browser." + - "Pass multiple browsers by repeating the option." + - "If using BrowserStack, specify browsers using --browserstack.", - default: [ "chrome" ] - } ) - .option( "headless", { - alias: "h", - type: "boolean", - description: - "Run tests in headless mode. Cannot be used with --debug or --browserstack.", - conflicts: [ "debug", "browserstack" ] - } ) - .option( "concurrency", { - alias: "c", - type: "number", - description: - "Run tests in parallel in multiple browsers. " + - "Defaults to 8 in normal mode. In browserstack mode, " + - "defaults to the maximum available under your BrowserStack plan." - } ) - .option( "debug", { - alias: "d", - type: "boolean", - description: - "Leave the browser open for debugging. Cannot be used with --headless.", - conflicts: [ "headless" ] - } ) - .option( "retries", { - alias: "r", - type: "number", - description: "Number of times to retry failed tests by refreshing the URL." - } ) - .option( "hard-retries", { - type: "number", - description: - "Number of times to retry failed tests by restarting the worker. " + - "This is in addition to the normal retries " + - "and are only used when the normal retries are exhausted." - } ) - .option( "verbose", { - alias: "v", - type: "boolean", - description: "Log additional information." - } ) - .option( "isolate", { - type: "boolean", - description: "Run each module by itself in the test page. This can extend testing time." - } ) - .option( "browserstack", { - type: "array", - description: - "Run tests in BrowserStack.\n" + - "Requires BROWSERSTACK_USERNAME and BROWSERSTACK_ACCESS_KEY environment variables.\n" + - "The value can be empty for the default configuration, or a string in the format of\n" + - "\"browser_[browserVersion | :device]_os_osVersion\" (see --list-browsers).\n" + - "Pass multiple browsers by repeating the option.\n" + - "The --browser option is ignored when --browserstack has a value.\n" + - "Otherwise, the --browser option will be used, " + - "with the latest version/device for that browser, on a matching OS." - } ) - .option( "run-id", { - type: "string", - description: "A unique identifier for the run in BrowserStack." - } ) - .option( "list-browsers", { - type: "string", - description: - "List available BrowserStack browsers and exit.\n" + - "Leave blank to view all browsers or pass " + - "\"browser_[browserVersion | :device]_os_osVersion\" with each parameter " + - "separated by an underscore to filter the list (any can be omitted).\n" + - "\"latest\" can be used in place of \"browserVersion\" to find the latest version.\n" + - "\"latest-n\" can be used to find the nth latest browser version.\n" + - "Use a colon to indicate a device.\n" + - "Examples: \"chrome__windows_10\", \"safari_latest\", " + - "\"Mobile Safari\", \"Android Browser_:Google Pixel 8 Pro\".\n" + - "Use quotes if spaces are necessary." - } ) - .option( "stop-workers", { - type: "boolean", - description: - "WARNING: This will stop all BrowserStack workers that may exist and exit," + - "including any workers running from other projects.\n" + - "This can be used as a failsafe when there are too many stray workers." - } ) - .option( "browserstack-plan", { - type: "boolean", - description: "Show BrowserStack plan information and exit." - } ) - .help().argv; - -if ( typeof argv.listBrowsers === "string" ) { - listBrowsers( buildBrowserFromString( argv.listBrowsers ) ); -} else if ( argv.stopWorkers ) { - stopWorkers(); -} else if ( argv.browserstackPlan ) { - console.log( await getPlan() ); -} else { - run( argv ); -} diff --git a/test/runner/createTestServer.js b/test/runner/createTestServer.js deleted file mode 100644 index 977b3e06..00000000 --- a/test/runner/createTestServer.js +++ /dev/null @@ -1,67 +0,0 @@ -import bodyParser from "body-parser"; -import express from "express"; -import bodyParserErrorHandler from "express-body-parser-error-handler"; -import { readFile } from "node:fs/promises"; - -const jqueryDir = process.env.JQUERY_DIRECTORY || "../jquery"; - -export async function createTestServer( report ) { - const indexHTML = await readFile( "./test/index.html", "utf8" ); - const app = express(); - - // Redirect home to test page - app.get( "/", ( _req, res ) => { - res.redirect( "/test/" ); - } ); - - // Redirect to trailing slash - app.use( ( req, res, next ) => { - if ( req.path === "/test" ) { - const query = req.url.slice( req.path.length ); - res.redirect( 301, `${ req.path }/${ query }` ); - } else { - next(); - } - } ); - - // Add a script tag to the index.html to load the QUnit listeners - app.use( /\/test(?:\/index.html)?\//, ( _req, res ) => { - res.send( - indexHTML.replace( - "", - "" - ) - ); - } ); - - // Bind the reporter - app.post( - "/api/report", - bodyParser.json( { limit: "50mb" } ), - async( req, res ) => { - if ( report ) { - const response = await report( req.body ); - if ( response ) { - res.json( response ); - return; - } - } - res.sendStatus( 204 ); - } - ); - - // Handle errors from the body parser - app.use( bodyParserErrorHandler() ); - - // Serve static files - app.use( "/dist", express.static( "dist" ) ); - app.use( "/src", express.static( "src" ) ); - app.use( "/test", express.static( "test" ) ); - app.use( "/external", express.static( "external" ) ); - - // Serve development jQuery, which is expected to be - // a sibling of the jquery-migrate repo by default. - app.use( "/jquery", express.static( jqueryDir ) ); - - return app; -} diff --git a/test/runner/flags/browsers.js b/test/runner/flags/browsers.js deleted file mode 100644 index 5d2306af..00000000 --- a/test/runner/flags/browsers.js +++ /dev/null @@ -1,24 +0,0 @@ -// This list is static, so no requests are required -// in the command help menu. - -import { getBrowsers } from "../browserstack/api.js"; - -export const browsers = [ - "chrome", - "ie", - "firefox", - "edge", - "safari", - "opera", - "yandex", - "IE Mobile", - "Android Browser", - "Mobile Safari" -]; - -// A function that can be used to update the above list. -export async function getAvailableBrowsers() { - const browsers = await getBrowsers( { flat: true } ); - const available = [ ...new Set( browsers.map( ( { browser } ) => browser ) ) ]; - return available; -} diff --git a/test/runner/flags/jquery-migrate.js b/test/runner/flags/jquery-migrate.js deleted file mode 100644 index f67c52a3..00000000 --- a/test/runner/flags/jquery-migrate.js +++ /dev/null @@ -1,17 +0,0 @@ -// Versions of jQuery Migrate listed in the QUnit select - -export const jqueryMigrate = [ - "dev", - "min", - "git", - "3.4.1", - "3.4.0", - "3.3.2", - "3.3.1", - "3.3.0", - "3.2.0", - "3.1.0", - "3.0.1", - "3.0.0", - "esmodules" -]; diff --git a/test/runner/flags/jquery.js b/test/runner/flags/jquery.js deleted file mode 100644 index 16024ee1..00000000 --- a/test/runner/flags/jquery.js +++ /dev/null @@ -1,30 +0,0 @@ -// Versions of jQuery listed in the QUnit select - -export const jquery = [ - "dev", - "min", - "git", - "git.min", - "git.slim", - "git.slim.min", - "3.x-git", - "3.x-git.min", - "3.x-git.slim", - "3.x-git.slim.min", - "3.7.1", - "3.7.1.slim", - "3.6.4", - "3.6.4.slim", - "3.5.1", - "3.5.1.slim", - "3.4.1", - "3.4.1.slim", - "3.3.1", - "3.3.1.slim", - "3.2.1", - "3.2.1.slim", - "3.1.1", - "3.1.1.slim", - "3.0.0", - "3.0.0.slim" -]; diff --git a/test/runner/flags/modules.js b/test/runner/flags/modules.js deleted file mode 100644 index 594702fd..00000000 --- a/test/runner/flags/modules.js +++ /dev/null @@ -1,16 +0,0 @@ -export const modules = [ - "migrate", - "core", - "ajax", - "attributes", - "css", - "data", - "deferred", - "effects", - "event", - "manipulation", - "offset", - "selector", - "serialize", - "traversing" -]; diff --git a/test/runner/lib/buildTestUrl.js b/test/runner/lib/buildTestUrl.js deleted file mode 100644 index 195d72ae..00000000 --- a/test/runner/lib/buildTestUrl.js +++ /dev/null @@ -1,32 +0,0 @@ -import { generateModuleId } from "./generateHash.js"; - -export function buildTestUrl( - modules, - { browserstack, jquery, jqueryMigrate, port, reportId } -) { - if ( !port ) { - throw new Error( "No port specified." ); - } - - const query = new URLSearchParams(); - for ( const module of modules ) { - query.append( "moduleId", generateModuleId( module ) ); - } - - if ( jquery ) { - query.append( "jquery", jquery ); - } - - if ( jqueryMigrate ) { - query.append( "plugin", jqueryMigrate ); - } - - if ( reportId ) { - query.append( "reportId", reportId ); - } - - // BrowserStack supplies a custom domain for local testing, - // which is especially necessary for iOS testing. - const host = browserstack ? "bs-local.com" : "localhost"; - return `http://${ host }:${ port }/test/?${ query }`; -} diff --git a/test/runner/lib/generateHash.js b/test/runner/lib/generateHash.js deleted file mode 100644 index dbbd4b47..00000000 --- a/test/runner/lib/generateHash.js +++ /dev/null @@ -1,50 +0,0 @@ -import crypto from "node:crypto"; - -export function generateHash( string ) { - const hash = crypto.createHash( "md5" ); - hash.update( string ); - - // QUnit hashes are 8 characters long - // We use 10 characters to be more visually distinct - return hash.digest( "hex" ).slice( 0, 10 ); -} - -/** - * A copy of the generate hash function from QUnit, - * used to generate a hash for the module name. - * - * QUnit errors on passing multiple modules to the - * module query parameter. We need to know - * the hash for each module before loading QUnit - * in order to pass multiple moduleId parameters instead. - */ -export function generateModuleId( module, browser ) { - - // QUnit normally hashes the test name, but - // we've repurposed this function to generate - // report IDs for module/browser combinations. - // We still use it without the browser parameter - // to get the same module IDs as QUnit to pass - // multiple ahead-of-time in the query string. - const str = module + "\x1C" + browser; - let hash = 0; - - for ( let i = 0; i < str.length; i++ ) { - hash = ( hash << 5 ) - hash + str.charCodeAt( i ); - hash |= 0; - } - - let hex = ( 0x100000000 + hash ).toString( 16 ); - if ( hex.length < 8 ) { - hex = "0000000" + hex; - } - - return hex.slice( -8 ); -} - -export function printModuleHashes( modules ) { - console.log( "Module hashes:" ); - modules.forEach( ( module ) => { - console.log( ` ${ module }: ${ generateModuleId( module ) }` ); - } ); -} diff --git a/test/runner/lib/getBrowserString.js b/test/runner/lib/getBrowserString.js deleted file mode 100644 index 0d293074..00000000 --- a/test/runner/lib/getBrowserString.js +++ /dev/null @@ -1,48 +0,0 @@ -const browserMap = { - chrome: "Chrome", - edge: "Edge", - firefox: "Firefox", - ie: "IE", - opera: "Opera", - safari: "Safari" -}; - -export function browserSupportsHeadless( browser ) { - browser = browser.toLowerCase(); - return ( - browser === "chrome" || - browser === "firefox" || - browser === "edge" - ); -} - -export function getBrowserString( - { - browser, - browser_version: browserVersion, - device, - os, - os_version: osVersion - }, - headless -) { - browser = browser.toLowerCase(); - browser = browserMap[ browser ] || browser; - let str = browser; - if ( browserVersion ) { - str += ` ${ browserVersion }`; - } - if ( device ) { - str += ` for ${ device }`; - } - if ( os ) { - str += ` on ${ os }`; - } - if ( osVersion ) { - str += ` ${ osVersion }`; - } - if ( headless && browserSupportsHeadless( browser ) ) { - str += " (headless)"; - } - return str; -} diff --git a/test/runner/lib/prettyMs.js b/test/runner/lib/prettyMs.js deleted file mode 100644 index 99bae2b3..00000000 --- a/test/runner/lib/prettyMs.js +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Pretty print a time in milliseconds. - */ -export function prettyMs( time ) { - const minutes = Math.floor( time / 60000 ); - const seconds = Math.floor( time / 1000 ); - const ms = Math.floor( time % 1000 ); - - let prettyTime = `${ ms }ms`; - if ( seconds > 0 ) { - prettyTime = `${ seconds }s ${ prettyTime }`; - } - if ( minutes > 0 ) { - prettyTime = `${ minutes }m ${ prettyTime }`; - } - - return prettyTime; -} diff --git a/test/runner/listeners.js b/test/runner/listeners.js deleted file mode 100644 index 61a98e7c..00000000 --- a/test/runner/listeners.js +++ /dev/null @@ -1,110 +0,0 @@ -( function() { - - "use strict"; - - // Get the report ID from the URL. - var match = location.search.match( /reportId=([^&]+)/ ); - if ( !match ) { - return; - } - var id = match[ 1 ]; - - // Adopted from https://github.com/douglascrockford/JSON-js - // Support: IE 11+ - // Using the replacer argument of JSON.stringify in IE has issues - // TODO: Replace this with a circular replacer + JSON.stringify + WeakSet - function decycle( object ) { - var objects = []; - - // The derez function recurses through the object, producing the deep copy. - function derez( value ) { - if ( - typeof value === "object" && - value !== null && - !( value instanceof Boolean ) && - !( value instanceof Date ) && - !( value instanceof Number ) && - !( value instanceof RegExp ) && - !( value instanceof String ) - ) { - - // Return a string early for elements - if ( value.nodeType ) { - return value.toString(); - } - - if ( objects.indexOf( value ) > -1 ) { - return; - } - - objects.push( value ); - - if ( Array.isArray( value ) ) { - - // If it is an array, replicate the array. - return value.map( derez ); - } else { - - // If it is an object, replicate the object. - var nu = Object.create( null ); - Object.keys( value ).forEach( function( name ) { - nu[ name ] = derez( value[ name ] ); - } ); - return nu; - } - } - - // Serialize Symbols as string representations so they are - // sent over the wire after being stringified. - if ( typeof value === "symbol" ) { - - // We can *describe* unique symbols, but note that their identity - // (e.g., `Symbol() !== Symbol()`) is lost - var ctor = Symbol.keyFor( value ) !== undefined ? "Symbol.for" : "Symbol"; - return ctor + "(" + JSON.stringify( value.description ) + ")"; - } - - return value; - } - return derez( object ); - } - - function send( type, data ) { - var json = JSON.stringify( { - id: id, - type: type, - data: data ? decycle( data ) : undefined - } ); - var request = new XMLHttpRequest(); - request.open( "POST", "/api/report", true ); - request.setRequestHeader( "Content-Type", "application/json" ); - request.send( json ); - return request; - } - - // Send acknowledgement to the server. - send( "ack" ); - - QUnit.on( "testEnd", function( data ) { - send( "testEnd", data ); - } ); - - QUnit.on( "runEnd", function( data ) { - - // Reduce the payload size. - // childSuites is large and unused. - data.childSuites = undefined; - - var request = send( "runEnd", data ); - request.onload = function() { - if ( request.status === 200 && request.responseText ) { - try { - var json = JSON.parse( request.responseText ); - window.location = json.url; - } catch ( e ) { - console.error( e ); - } - } - }; - } ); -} )(); diff --git a/test/runner/package.json b/test/runner/package.json deleted file mode 100644 index bedb411a..00000000 --- a/test/runner/package.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "type": "module" -} diff --git a/test/runner/queue.js b/test/runner/queue.js deleted file mode 100644 index 843d5672..00000000 --- a/test/runner/queue.js +++ /dev/null @@ -1,119 +0,0 @@ -import chalk from "chalk"; -import { getBrowserString } from "./lib/getBrowserString.js"; -import { - checkLastTouches, - createBrowserWorker, - restartBrowser, - setBrowserWorkerUrl -} from "./browsers.js"; - -const TEST_POLL_TIMEOUT = 1000; - -const queue = []; - -export function getNextBrowserTest( reportId ) { - const index = queue.findIndex( ( test ) => test.id === reportId ); - if ( index === -1 ) { - return; - } - - // Remove the completed test from the queue - const previousTest = queue[ index ]; - queue.splice( index, 1 ); - - // Find the next test for the same browser - for ( const test of queue.slice( index ) ) { - if ( test.fullBrowser === previousTest.fullBrowser ) { - - // Set the URL for our tracking - setBrowserWorkerUrl( test.browser, test.url ); - test.running = true; - - // Return the URL for the next test. - // listeners.js will use this to set the browser URL. - return { url: test.url }; - } - } -} - -export function retryTest( reportId, maxRetries ) { - if ( !maxRetries ) { - return; - } - const test = queue.find( ( test ) => test.id === reportId ); - if ( test ) { - test.retries++; - if ( test.retries <= maxRetries ) { - console.log( - `\nRetrying test ${ reportId } for ${ chalk.yellow( - test.options.modules.join( ", " ) - ) }...${ test.retries }` - ); - return test; - } - } -} - -export async function hardRetryTest( reportId, maxHardRetries ) { - if ( !maxHardRetries ) { - return false; - } - const test = queue.find( ( test ) => test.id === reportId ); - if ( test ) { - test.hardRetries++; - if ( test.hardRetries <= maxHardRetries ) { - console.log( - `\nHard retrying test ${ reportId } for ${ chalk.yellow( - test.options.modules.join( ", " ) - ) }...${ test.hardRetries }` - ); - await restartBrowser( test.browser ); - return true; - } - } - return false; -} - -export function addRun( url, browser, options ) { - queue.push( { - browser, - fullBrowser: getBrowserString( browser ), - hardRetries: 0, - id: options.reportId, - url, - options, - retries: 0, - running: false - } ); -} - -export async function runAll() { - return new Promise( async( resolve, reject ) => { - while ( queue.length ) { - try { - await checkLastTouches(); - } catch ( error ) { - reject( error ); - } - - // Run one test URL per browser at a time - const browsersTaken = []; - for ( const test of queue ) { - if ( browsersTaken.indexOf( test.fullBrowser ) > -1 ) { - continue; - } - browsersTaken.push( test.fullBrowser ); - if ( !test.running ) { - test.running = true; - try { - await createBrowserWorker( test.url, test.browser, test.options ); - } catch ( error ) { - reject( error ); - } - } - } - await new Promise( ( resolve ) => setTimeout( resolve, TEST_POLL_TIMEOUT ) ); - } - resolve(); - } ); -} diff --git a/test/runner/reporter.js b/test/runner/reporter.js deleted file mode 100644 index 91cdd297..00000000 --- a/test/runner/reporter.js +++ /dev/null @@ -1,138 +0,0 @@ -import chalk from "chalk"; -import { getBrowserString } from "./lib/getBrowserString.js"; -import { prettyMs } from "./lib/prettyMs.js"; -import * as Diff from "diff"; - -function serializeForDiff( value ) { - - // Use naive serialization for everything except types with confusable values - if ( typeof value === "string" ) { - return JSON.stringify( value ); - } - if ( typeof value === "bigint" ) { - return `${ value }n`; - } - return `${ value }`; -} - -export function reportTest( test, reportId, { browser, headless } ) { - if ( test.status === "passed" ) { - - // Write to console without newlines - process.stdout.write( "." ); - return; - } - - let message = `${ chalk.bold( `${ test.suiteName }: ${ test.name }` ) }`; - message += `\nTest ${ test.status } on ${ chalk.yellow( - getBrowserString( browser, headless ) - ) } (${ chalk.bold( reportId ) }).`; - - // test.assertions only contains passed assertions; - // test.errors contains all failed asssertions - if ( test.errors.length ) { - for ( const error of test.errors ) { - message += "\n"; - if ( error.message ) { - message += `\n${ error.message }`; - } - message += `\n${ chalk.gray( error.stack ) }`; - - // Show expected and actual values - // if either is defined and non-null. - // error.actual is set to null for failed - // assert.expect() assertions, so skip those as well. - // This should be fine because error.expected would - // have to also be null for this to be skipped. - if ( error.expected != null || error.actual != null ) { - message += `\nexpected: ${ chalk.red( JSON.stringify( error.expected ) ) }`; - message += `\nactual: ${ chalk.green( JSON.stringify( error.actual ) ) }`; - let diff; - - if ( Array.isArray( error.expected ) && Array.isArray( error.actual ) ) { - - // Diff arrays - diff = Diff.diffArrays( error.expected, error.actual ); - } else if ( - typeof error.expected === "object" && - typeof error.actual === "object" - ) { - - // Diff objects - diff = Diff.diffJson( error.expected, error.actual ); - } else if ( - typeof error.expected === "number" && - typeof error.actual === "number" - ) { - - // Diff numbers directly - const value = error.actual - error.expected; - if ( value > 0 ) { - diff = [ { added: true, value: `+${ value }` } ]; - } else { - diff = [ { removed: true, value: `${ value }` } ]; - } - } else if ( - typeof error.expected === "string" && - typeof error.actual === "string" - ) { - - // Diff the characters of strings - diff = Diff.diffChars( error.expected, error.actual ); - } else { - - // Diff everything else as words - diff = Diff.diffWords( - serializeForDiff( error.expected ), - serializeForDiff( error.actual ) - ); - } - - if ( diff ) { - message += "\n"; - message += diff - .map( ( part ) => { - if ( part.added ) { - return chalk.green( part.value ); - } - if ( part.removed ) { - return chalk.red( part.value ); - } - return chalk.gray( part.value ); - } ) - .join( "" ); - } - } - } - } - - console.log( `\n\n${ message }` ); - - // Only return failed messages - if ( test.status === "failed" ) { - return message; - } -} - -export function reportEnd( - result, - reportId, - { browser, headless, jquery, jqueryMigrate, modules } -) { - const fullBrowser = getBrowserString( browser, headless ); - console.log( - `\n\nTests finished in ${ prettyMs( result.runtime ) } ` + - `for ${ chalk.yellow( modules.join( ", " ) ) } ` + - `for jQuery Migrate ${ chalk.yellow( jqueryMigrate ) } ` + - `and jQuery ${ chalk.yellow( jquery ) } ` + - `in ${ chalk.yellow( fullBrowser ) } (${ chalk.bold( reportId ) })...` - ); - console.log( - ( result.status !== "passed" ? - `${ chalk.red( result.testCounts.failed ) } failed. ` : - "" ) + - `${ chalk.green( result.testCounts.total ) } passed. ` + - `${ chalk.gray( result.testCounts.skipped ) } skipped.` - ); - return result.testCounts; -} diff --git a/test/runner/run.js b/test/runner/run.js deleted file mode 100644 index 69ef86bd..00000000 --- a/test/runner/run.js +++ /dev/null @@ -1,355 +0,0 @@ -import chalk from "chalk"; -import { asyncExitHook, gracefulExit } from "exit-hook"; -import { getLatestBrowser } from "./browserstack/api.js"; -import { buildBrowserFromString } from "./browserstack/buildBrowserFromString.js"; -import { localTunnel } from "./browserstack/local.js"; -import { reportEnd, reportTest } from "./reporter.js"; -import { createTestServer } from "./createTestServer.js"; -import { buildTestUrl } from "./lib/buildTestUrl.js"; -import { generateHash, printModuleHashes } from "./lib/generateHash.js"; -import { getBrowserString } from "./lib/getBrowserString.js"; -import { modules as allModules } from "./flags/modules.js"; -import { cleanupAllBrowsers, touchBrowser } from "./browsers.js"; -import { - addRun, - getNextBrowserTest, - hardRetryTest, - retryTest, - runAll -} from "./queue.js"; - -const EXIT_HOOK_WAIT_TIMEOUT = 60 * 1000; - -export async function run( { - browser: browserNames = [], - browserstack, - concurrency, - debug, - hardRetries, - headless, - isolate, - jquery: jquerys = [], - jqueryMigrate: jqueryMigrates = [], - module: modules = [], - retries = 0, - runId, - verbose -} ) { - if ( !browserNames.length ) { - browserNames = [ "chrome" ]; - } - if ( !modules.length ) { - modules = allModules; - } - if ( !jquerys.length ) { - jquerys = [ "3.x-git.min" ]; - } - if ( !jqueryMigrates.length ) { - jqueryMigrates = [ "min" ]; - } - if ( headless && debug ) { - throw new Error( - "Cannot run in headless mode and debug mode at the same time." - ); - } - - if ( verbose ) { - console.log( browserstack ? "Running in BrowserStack." : "Running locally." ); - } - - const errorMessages = []; - const pendingErrors = {}; - - // Convert browser names to browser objects - let browsers = browserNames.map( ( b ) => ( { browser: b } ) ); - const tunnelId = generateHash( - `${ Date.now() }-${ modules.join( ":" ) }-${ ( browserstack || [] ) - .concat( browserNames ) - .join( ":" ) }` - ); - - // A unique identifier for this run - if ( !runId ) { - runId = tunnelId; - } - - // Create the test app and - // hook it up to the reporter - const reports = Object.create( null ); - const app = await createTestServer( async( message ) => { - switch ( message.type ) { - case "testEnd": { - const reportId = message.id; - const report = reports[ reportId ]; - touchBrowser( report.browser ); - const errors = reportTest( message.data, reportId, report ); - pendingErrors[ reportId ] ??= Object.create( null ); - if ( errors ) { - pendingErrors[ reportId ][ message.data.name ] = errors; - } else { - const existing = pendingErrors[ reportId ][ message.data.name ]; - - // Show a message for flakey tests - if ( existing ) { - console.log(); - console.warn( - chalk.italic( - chalk.gray( existing.replace( "Test failed", "Test flakey" ) ) - ) - ); - console.log(); - delete pendingErrors[ reportId ][ message.data.name ]; - } - } - break; - } - case "runEnd": { - const reportId = message.id; - const report = reports[ reportId ]; - touchBrowser( report.browser ); - const { failed, total } = reportEnd( - message.data, - message.id, - reports[ reportId ] - ); - report.total = total; - - // Handle failure - if ( failed ) { - const retry = retryTest( reportId, retries ); - - // Retry if retryTest returns a test - if ( retry ) { - return retry; - } - - // Return early if hardRetryTest returns true - if ( await hardRetryTest( reportId, hardRetries ) ) { - return; - } - errorMessages.push( ...Object.values( pendingErrors[ reportId ] ) ); - } - - // Run the next test - return getNextBrowserTest( reportId ); - } - case "ack": { - const report = reports[ message.id ]; - touchBrowser( report.browser ); - break; - } - default: - console.warn( "Received unknown message type:", message.type ); - } - } ); - - // Start up local test server - let server; - let port; - await new Promise( ( resolve ) => { - - // Pass 0 to choose a random, unused port - server = app.listen( 0, () => { - port = server.address().port; - resolve(); - } ); - } ); - - if ( !server || !port ) { - throw new Error( "Server not started." ); - } - - if ( verbose ) { - console.log( `Server started on port ${ port }.` ); - } - - function stopServer() { - return new Promise( ( resolve ) => { - server.close( () => { - if ( verbose ) { - console.log( "Server stopped." ); - } - resolve(); - } ); - } ); - } - - async function cleanup() { - console.log( "Cleaning up..." ); - - await cleanupAllBrowsers( { verbose } ); - - if ( tunnel ) { - await tunnel.stop(); - if ( verbose ) { - console.log( "Stopped BrowserStackLocal." ); - } - } - } - - asyncExitHook( - async() => { - await cleanup(); - await stopServer(); - }, - { wait: EXIT_HOOK_WAIT_TIMEOUT } - ); - - // Start up BrowserStackLocal - let tunnel; - if ( browserstack ) { - if ( headless ) { - console.warn( - chalk.italic( - "BrowserStack does not support headless mode. Running in normal mode." - ) - ); - headless = false; - } - - // Convert browserstack to browser objects. - // If browserstack is an empty array, fall back - // to the browsers array. - if ( browserstack.length ) { - browsers = browserstack.map( ( b ) => { - if ( !b ) { - return browsers[ 0 ]; - } - return buildBrowserFromString( b ); - } ); - } - - // Fill out browser defaults - browsers = await Promise.all( - browsers.map( async( browser ) => { - - // Avoid undici connect timeout errors - await new Promise( ( resolve ) => setTimeout( resolve, 100 ) ); - - const latestMatch = await getLatestBrowser( browser ); - if ( !latestMatch ) { - console.error( - chalk.red( `Browser not found: ${ getBrowserString( browser ) }.` ) - ); - gracefulExit( 1 ); - } - return latestMatch; - } ) - ); - - tunnel = await localTunnel( tunnelId ); - if ( verbose ) { - console.log( "Started BrowserStackLocal." ); - - printModuleHashes( modules ); - } - } - - function queueRuns( modules, browser ) { - const fullBrowser = getBrowserString( browser, headless ); - - for ( const jqueryMigrate of jqueryMigrates ) { - for ( const jquery of jquerys ) { - const reportId = generateHash( - `${ jqueryMigrate } ${ jquery } ${ modules.join( ":" ) } ${ fullBrowser }` - ); - reports[ reportId ] = { - browser, - headless, - jquery, - jqueryMigrate, - modules - }; - - const url = buildTestUrl( modules, { - browserstack, - jquery, - jqueryMigrate, - port, - reportId - } ); - - const options = { - browserstack, - concurrency, - debug, - headless, - jquery, - jqueryMigrate, - modules, - reportId, - runId, - tunnelId, - verbose - }; - - addRun( url, browser, options ); - } - } - } - - for ( const browser of browsers ) { - if ( isolate ) { - for ( const module of modules ) { - queueRuns( [ module ], browser ); - } - } else { - queueRuns( modules, browser ); - } - } - - try { - console.log( `Starting Run ${ runId }...` ); - await runAll(); - } catch ( error ) { - console.error( error ); - if ( !debug ) { - gracefulExit( 1 ); - } - } finally { - console.log(); - if ( errorMessages.length === 0 ) { - let stop = false; - for ( const report of Object.values( reports ) ) { - if ( !report.total ) { - stop = true; - console.error( - chalk.red( - `No tests were run for ${ report.modules.join( - ", " - ) } in ${ getBrowserString( report.browser ) }` - ) - ); - } - } - if ( stop ) { - return gracefulExit( 1 ); - } - console.log( chalk.green( "All tests passed!" ) ); - - if ( !debug || browserstack ) { - gracefulExit( 0 ); - } - } else { - console.error( chalk.red( `${ errorMessages.length } tests failed.` ) ); - console.log( - errorMessages.map( ( error, i ) => `\n${ i + 1 }. ${ error }` ).join( "\n" ) - ); - - if ( debug ) { - console.log(); - if ( browserstack ) { - console.log( "Leaving browsers with failures open for debugging." ); - console.log( - "View running sessions at https://automate.browserstack.com/dashboard/v2/" - ); - } else { - console.log( "Leaving browsers open for debugging." ); - } - console.log( "Press Ctrl+C to exit." ); - } else { - gracefulExit( 1 ); - } - } - } -} diff --git a/test/runner/selenium/createDriver.js b/test/runner/selenium/createDriver.js deleted file mode 100644 index df120476..00000000 --- a/test/runner/selenium/createDriver.js +++ /dev/null @@ -1,97 +0,0 @@ -import { Builder, Capabilities, logging } from "selenium-webdriver"; -import Chrome from "selenium-webdriver/chrome.js"; -import Edge from "selenium-webdriver/edge.js"; -import Firefox from "selenium-webdriver/firefox.js"; -import IE from "selenium-webdriver/ie.js"; -import { browserSupportsHeadless } from "../lib/getBrowserString.js"; - -// Set script timeout to 10min -const DRIVER_SCRIPT_TIMEOUT = 1000 * 60 * 10; - -export default async function createDriver( { browserName, headless, url, verbose } ) { - const capabilities = Capabilities[ browserName ](); - - // Support: IE 11+ - // When those are set for IE, the process crashes with an error: - // "Unable to match capability set 0: goog:loggingPrefs is an unknown - // extension capability for IE". - if ( browserName !== "ie" ) { - const prefs = new logging.Preferences(); - prefs.setLevel( logging.Type.BROWSER, logging.Level.ALL ); - capabilities.setLoggingPrefs( prefs ); - } - - let driver = new Builder().withCapabilities( capabilities ); - - const chromeOptions = new Chrome.Options(); - chromeOptions.addArguments( "--enable-chrome-browser-cloud-management" ); - - // Alter the chrome binary path if - // the CHROME_BIN environment variable is set - if ( process.env.CHROME_BIN ) { - if ( verbose ) { - console.log( `Setting chrome binary to ${ process.env.CHROME_BIN }` ); - } - chromeOptions.setChromeBinaryPath( process.env.CHROME_BIN ); - } - - const firefoxOptions = new Firefox.Options(); - - if ( process.env.FIREFOX_BIN ) { - if ( verbose ) { - console.log( `Setting firefox binary to ${ process.env.FIREFOX_BIN }` ); - } - - firefoxOptions.setBinary( process.env.FIREFOX_BIN ); - } - - const edgeOptions = new Edge.Options(); - edgeOptions.addArguments( "--enable-chrome-browser-cloud-management" ); - - // Alter the edge binary path if - // the EDGE_BIN environment variable is set - if ( process.env.EDGE_BIN ) { - if ( verbose ) { - console.log( `Setting edge binary to ${ process.env.EDGE_BIN }` ); - } - edgeOptions.setEdgeChromiumBinaryPath( process.env.EDGE_BIN ); - } - - const ieOptions = new IE.Options(); - ieOptions.setEdgeChromium( true ); - ieOptions.setEdgePath( "C:/Program Files (x86)/Microsoft/Edge/Application/msedge.exe" ); - - if ( headless ) { - chromeOptions.addArguments( "--headless=new" ); - firefoxOptions.addArguments( "--headless" ); - edgeOptions.addArguments( "--headless=new" ); - if ( !browserSupportsHeadless( browserName ) ) { - console.log( - `Headless mode is not supported for ${ browserName }.` + - "Running in normal mode instead." - ); - } - } - - driver = await driver - .setChromeOptions( chromeOptions ) - .setFirefoxOptions( firefoxOptions ) - .setEdgeOptions( edgeOptions ) - .setIeOptions( ieOptions ) - .build(); - - if ( verbose ) { - const driverCapabilities = await driver.getCapabilities(); - const name = driverCapabilities.getBrowserName(); - const version = driverCapabilities.getBrowserVersion(); - console.log( `\nDriver created for ${ name } ${ version }` ); - } - - // Increase script timeout to 10min - await driver.manage().setTimeouts( { script: DRIVER_SCRIPT_TIMEOUT } ); - - // Set the first URL for the browser - await driver.get( url ); - - return driver; -} diff --git a/test/runner/server.js b/test/runner/server.js deleted file mode 100644 index 09fe0da4..00000000 --- a/test/runner/server.js +++ /dev/null @@ -1,13 +0,0 @@ -import { createTestServer } from "./createTestServer.js"; - -const port = process.env.PORT || 3000; - -async function runServer() { - const app = await createTestServer(); - - app.listen( { port, host: "0.0.0.0" }, function() { - console.log( `Open tests at http://localhost:${ port }/test/` ); - } ); -} - -runServer();