Skip to content

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

chore: bump commander.js version to 13 (#36426)

Yury Semikhatsky04b10c56c1bd
diff --git a/packages/playwright-core/ThirdPartyNotices.txt b/packages/playwright-core/ThirdPartyNotices.txt
index 744720e00d..d2aeb156ad 100644
--- a/packages/playwright-core/ThirdPartyNotices.txt
+++ b/packages/playwright-core/ThirdPartyNotices.txt
@@ -10,7 +10,7 @@ This project incorporates components from the projects listed below. The origina
- [email protected] (https://github.com/brianloveswords/buffer-crc32)
- [email protected] (https://github.com/codemirror/CodeMirror)
- [email protected] (https://github.com/Marak/colors.js)
-- [email protected] (https://github.com/tj/commander.js)
+- [email protected] (https://github.com/tj/commander.js)
- [email protected] (https://github.com/substack/node-concat-map)
- [email protected] (https://github.com/debug-js/debug)
- [email protected] (https://github.com/debug-js/debug)
@@ -331,7 +331,7 @@ THE SOFTWARE.
=========================================
END OF [email protected] AND INFORMATION
-%% [email protected] NOTICES AND INFORMATION BEGIN HERE
+%% [email protected] NOTICES AND INFORMATION BEGIN HERE
=========================================
(The MIT License)
@@ -356,7 +356,7 @@ CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
=========================================
-END OF [email protected] AND INFORMATION
+END OF [email protected] AND INFORMATION
%% [email protected] NOTICES AND INFORMATION BEGIN HERE
=========================================
diff --git a/packages/playwright-core/bundles/utils/package-lock.json b/packages/playwright-core/bundles/utils/package-lock.json
index bc58353c99..7646662695 100644
--- a/packages/playwright-core/bundles/utils/package-lock.json
+++ b/packages/playwright-core/bundles/utils/package-lock.json
@@ -9,7 +9,7 @@
"version": "0.0.1",
"dependencies": {
"colors": "1.4.0",
- "commander": "8.3.0",
+ "commander": "^13.0.0",
"debug": "^4.3.4",
"diff": "^7.0.0",
"dotenv": "^16.4.5",
@@ -173,11 +173,12 @@
}
},
"node_modules/commander": {
- "version": "8.3.0",
- "resolved": "https://registry.npmjs.org/commander/-/commander-8.3.0.tgz",
- "integrity": "sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww==",
+ "version": "13.1.0",
+ "resolved": "https://registry.npmjs.org/commander/-/commander-13.1.0.tgz",
+ "integrity": "sha512-/rFeCpNJQbhSZjGVwO9RFV3xPqbnERS8MmIQzCtD/zl6gpJuV/bMLuN92oG3F7d8oDEHHRrujSXNUr8fpjntKw==",
+ "license": "MIT",
"engines": {
- "node": ">= 12"
+ "node": ">=18"
}
},
"node_modules/concat-map": {
diff --git a/packages/playwright-core/bundles/utils/package.json b/packages/playwright-core/bundles/utils/package.json
index 7e7ff502ba..c0559de57d 100644
--- a/packages/playwright-core/bundles/utils/package.json
+++ b/packages/playwright-core/bundles/utils/package.json
@@ -4,7 +4,7 @@
"private": true,
"dependencies": {
"colors": "1.4.0",
- "commander": "8.3.0",
+ "commander": "^13.0.0",
"debug": "^4.3.4",
"diff": "^7.0.0",
"dotenv": "^16.4.5",
diff --git a/packages/playwright-core/src/cli/programWithTestStub.ts b/packages/playwright-core/src/cli/programWithTestStub.ts
index 29b5d87ed1..e7c4257526 100644
--- a/packages/playwright-core/src/cli/programWithTestStub.ts
+++ b/packages/playwright-core/src/cli/programWithTestStub.ts
@@ -55,7 +55,9 @@ const kExternalPlaywrightTestCommands = [
];
function addExternalPlaywrightTestCommands() {
for (const [command, description] of kExternalPlaywrightTestCommands) {
- const playwrightTest = program.command(command).allowUnknownOption(true);
+ const playwrightTest = program.command(command)
+ .allowUnknownOption(true)
+ .allowExcessArguments(true);
playwrightTest.description(`${description} Available in @playwright/test package.`);
playwrightTest.action(async () => {
printPlaywrightTestError(command);
diff --git a/packages/playwright/src/program.ts b/packages/playwright/src/program.ts
index 874f645001..9907a5a18c 100644
--- a/packages/playwright/src/program.ts
+++ b/packages/playwright/src/program.ts
@@ -382,7 +382,7 @@ const testOptions: [string, string][] = [
['--fully-parallel', `Run all tests in parallel (default: false)`],
['--global-timeout <timeout>', `Maximum time this test suite can run in milliseconds (default: unlimited)`],
['-g, --grep <grep>', `Only run tests matching this regular expression (default: ".*")`],
- ['-gv, --grep-invert <grep>', `Only run tests that do not match this regular expression`],
+ ['--grep-invert <grep>', `Only run tests that do not match this regular expression`],
['--headed', `Run tests in headed browsers (default: headless)`],
['--ignore-snapshots', `Ignore screenshot and snapshot expectations`],
['--last-failed', `Only re-run the failures`],