Registry / testing / ui5-test-runner

ui5-test-runner

JSON →
library5.13.1jsnpmunverified

ui5-test-runner is a standalone, self-sufficient test runner for UI5 applications, designed to execute tests in parallel across multiple browser instances. This approach effectively mitigates browser memory consumption issues and reduces overall test execution time, positioning it as a robust alternative to the UI5 Karma runner. The current stable version is 5.13.1, with frequent patch releases for bug fixes (monthly/bi-monthly) and minor feature releases every few months. Its key differentiators include its focus on parallel execution, optimized memory management for large UI5 test suites, and direct command-line interface usage, supporting various browser automation tools like Puppeteer, Selenium/WebDriver, and Playwright.

npm install ui5-test-runner
INSTALL
IMPORT
SIG · UI5-TEST-RUNNER
U
ui5-test-runner
testingjavascriptv5.13.1
Install
—
Import
—
Disk
—
Pass rate
0/ 6
Env Coverage0 / 6
glibc
18–22
musl
18–22
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18–226 runs
build_error
glibc
node 18–226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

CLI tool
✓ npx ui5-test-runner
✗ import { ui5TestRunner } from 'ui5-test-runner'
This package is primarily a command-line interface (CLI) tool. It is not designed for direct programmatic import as a library.
npm script
✓ "test": "ui5-test-runner --config ui5-runner.json"
✗ "test": "node node_modules/ui5-test-runner/bin/cli.js"
The recommended way to invoke the CLI locally within a project is via an npm script or 'npx'.

Demonstrates how to set up `ui5-test-runner` to execute UI5 unit and integration tests using a local Puppeteer Chromium instance with a basic `package.json` script and configuration file.

{ "name": "my-ui5-app", "version": "1.0.0", "description": "A sample UI5 application", "scripts": { "test": "ui5-test-runner --config ui5-runner.json" }, "devDependencies": { "ui5-test-runner": "^5.0.0", "puppeteer": "^22.0.0" } } // ui5-runner.json { "browsers": [ { "name": "chromium", "headless": true } ], "testPageUrls": [ "/test/unit/unitTests.qunit.html", "/test/integration/opaTests.qunit.html" ], "serve": { "module": "@ui5/server", "config": { "port": 8080, "root": "." } } } // To run: `npm test`
ui5-test-runner --version
Debug
Known issues
breakingStarting with v5.0.0, some coverage reports now include all files, even those without executed code, which may lead to a potential decrease in reported coverage percentages.
fix
Review and adjust your coverage thresholds, and configure `nyc` appropriately to exclude unwanted files or directories from coverage analysis.
affects: >=5.0.0
breakingVersion 4.0.0 dropped support for Node.js 16. The runner now requires Node.js 18 or higher.
fix
Upgrade your Node.js environment to version 18 or a more recent LTS release.
affects: >=4.0.0
breakingVersion 3.0.0 dropped support for Node.js 14, requiring Node.js 16 or higher at the time, which has since been superseded by the Node.js 18 requirement.
fix
Upgrade your Node.js environment to version 18 or higher.
affects: >=3.0.0 <4.0.0
breakingVersion 2.0.0 introduced significant changes to both command-line parameters and configuration file syntax, making it incompatible with configurations from prior major versions.
fix
Refer to the official documentation for v2.0.0 and above to update your command-line arguments and configuration files to the new syntax.
affects: >=2.0.0
breakingThe browser instantiation command evolved in an incompatible way with v2.0.0, requiring changes to how browsers are defined and launched.
fix
Consult the dedicated documentation section on browser configuration for `ui5-test-runner` v2.0.0+ to correctly set up your test browsers.
affects: >=2.0.0
gotchaFor UI5 remote tests, especially when running with Chrome or Playwright, local network access checks might block connections from insecure contexts (e.g., HTTP sites to private IPs). This issue was addressed in v5.11.0.
fix
Use the `--unsecure` option when running remote UI5 tests to bypass these local network access checks if appropriate for your testing environment.
affects: >=5.11.0
gotchaPrior to version 5.9.0, empty browser arguments were silently filtered out without explicit warnings, potentially leading to unexpected browser behavior or misconfiguration.
fix
Always ensure that browser arguments provided are valid and non-empty. For versions 5.9.0 and later, a warning will be issued if empty arguments are detected.
affects: <5.9.0
Errors
Common errors & fixes
Error: Node.js version not supported. Minimum required: 18.
Attempting to run `ui5-test-runner` with a Node.js version older than 18.
fix
Upgrade your Node.js installation to version 18 or a newer LTS release.
ERR! Test runner failed. Error: Timeout during test execution.
Tests are taking longer than the configured timeout, or there was an issue launching/connecting to a browser instance.
fix
Increase the `--timeout` option in your command or configuration, ensure your browser drivers are correctly set up, or investigate long-running test cases.
Error: Cannot find module 'puppeteer'
A browser requiring Puppeteer (e.g., 'chromium') is configured, but `puppeteer` is not installed as a local or global dependency.
fix
Install `puppeteer` as a dev dependency in your project: `npm install --save-dev puppeteer`, or globally if preferred: `npm install --global puppeteer`.
Error: Configuration file 'ui5-runner.json' not found or invalid.
The test runner cannot locate the specified configuration file, or the file contains syntax errors (e.g., invalid JSON/YAML).
fix
Verify the path to your configuration file (e.g., `--config my-config.json`) and ensure its content is valid.
Local network access to unsecure private network prevented.
The browser (e.g., Chrome) is blocking an insecure connection from the test runner to a local IP address during UI5 remote testing, due to new security policies.
fix
Add the `--unsecure` option to your `ui5-test-runner` command or configuration, specifically for remote tests requiring local network access.
Upgrade
Version history
5.13.1latest on npm
Audit
Dependencies
puppeteeroptionalUsed for browser automation when configured.
selenium-webdriveroptionalUsed for browser automation when configured.
nycoptionalRequired for code coverage reporting.
Agent activity
12 hits · last 30 days
node
10
Resources
ui5-test-runner — npm install ui5-test-runner · libregistry