pwc-p run
pwc-p run command documentation - orchestration execution for Playwright
pwc-p run starts orchestration and executes Playwright tests with load balancing across available workers. It distributes tests from the list produced by pwc-p discover for parallel execution.
Examples
Run the full suite with orchestration:
npx pwc-p run --key <record-key> --project-id <project-id> --ci-build-id <ci-build-id>Run tests from a discovery file (filtered earlier):
npx pwc-p discover --pwc-discovery-file tests.txt --grep @smoke
npx pwc-p run --key <record-key> --project-id <project-id> --ci-build-id <ci-build-id> --pwc-discovery-file tests.txtAdd Playwright runtime flags:
npx pwc-p run --key <record-key> --project-id <project-id> --ci-build-id <ci-build-id> -j 2 --timeout 10000Currents Configuration
These options configure how tests are recorded and reported in Currents.
--ci-build-id
The unique identifier for a run. See ciBuildId *.
-k, --key
Your secret Record Key obtained from Currents. See recordKey *.
-p, --project-id
The project ID for results reporting obtained from Currents. See projectId *.
-t, --tag
Comma-separated tag(s) for recorded runs in Currents. See tag.
--pwc-config <path>
Path to currents config file currents.config.[ts|js]. See Configuration Sources.
Discovery File
--pwc-discovery-file <path>
Path to the discovery output file written by pwc-p discover and read by pwc-p run. Also available as CURRENTS_DISCOVERY_FILE environment variable or orchestration.discoveryFile in currents.config.ts (recommended for CI so both commands use the same path).
Tag Handling
--pwc-remove-title-tags
Remove tags from test names in Currents, e.g. Test name @smoke becomes Test name in the dashboard (default: false). See removeTitleTags.
--pwc-disable-title-tags
Disable parsing tags from test title, e.g. Test name @smoke would not have tag smoke in the dashboard (default: false). See disableTitleTags.
--pwc-disable-test-tags
Prevent reporting tags defined in the test title or by test annotations (default: false). See disableTestTags.
Orchestration
--pwc-batch-size <auto|number>
Sets the number of parallel lanes the orchestrator fills per machine (defaults to auto, derived from your Playwright --workers). It is not a hard limit on how many spec files a machine claims — see Orchestration and Multiple Workers. See orchestration.batchSize.
--pwc-create-timeout-ms <milliseconds>
Milliseconds to wait for orchestration session creation during discovery and session setup (defaults to 60000). Increase for large test suites that exceed the default timeout. See orchestration.createTimeoutMs.
--pwc-reset-signal <SIGUSR1|SIGUSR2>
Specify a process signal to listen for to trigger a reset of the current in-progress tests. Only available on OS with POSIX signal support. See orchestration.resetSignal.
--pwc-skip-reporter-injection
Do not inject @currents/playwright. If set, you must add Currents reporter manually. See orchestration.skipReporterInjection.
--pwc-orchestration-id <string>
Unique identifier of the orchestration session this run belongs to. See orchestrationId.
--pwc-machine-id <string>
Unique identifier of the machine running the tests. Mostly used internally. If not provided, it will be generated automatically. See machineId.
--pwc-test-suite-file <path>
Path to the full test suite file for orchestration and reporting. See testSuiteFile.
--pwc-cancel-after-failures <number | false>
Abort the cloud run after the specified number of failed tests detected. Overrides the default Currents Project settings. See cancelAfterFailures.
--pwc-pending-child-exit-timeout-ms <number>
Force-exit pending Playwright child processes after the orchestration finishes if they do not exit within the configured timeout. See orchestration.pendingChildExitTimeoutMs.
Debugging & Output
--pwc-debug [boolean | "remote" | "full"]
Enable collecting debug logs for the reporter (default: false).
truewill print the debug logs to stdoutremotewill upload the debug logs to Currents serversfullwill print the logs to stdout and also upload to Currents
Environment variable: CURRENTS_DEBUG=true | "remote" | "full". See Troubleshooting.
--pwc-output-file <path>
File path for run summary output in JSON format. See outputFile.
--pwc-console-output <preset>
Reporter console output. See consoleOutput.
--pwc-coverage <project-name>
List of projects to collect coverage for, e.g. --pwc-coverage chromium --pwc-coverage firefox. If no projects are specified, coverage will be collected for all projects. See coverage.projects.
--pwc-coverage-dir <path>
Coverage reports directory path. See coverage.dir.
Runtime Flags
These flags are passed through to Playwright and control test execution:
-j, --workers <number>
Number of parallel workers (Playwright passthrough). For example, -j 2 runs tests with 2 workers.
--timeout <milliseconds>
Test timeout in milliseconds (Playwright passthrough). For example, --timeout 10000 sets a 10-second timeout.
See Playwright CLI reference for additional runtime flags.
Help
-V, --version
Show package version.
-h, --help
Show help message.
Last updated
Was this helpful?