Gathering detailed insights and metrics for wdio-qunit-service
Gathering detailed insights and metrics for wdio-qunit-service
Gathering detailed insights and metrics for wdio-qunit-service
Gathering detailed insights and metrics for wdio-qunit-service
npm install wdio-qunit-service
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
9 Stars
28 Commits
2 Forks
3 Watching
1 Branches
1 Contributors
Updated on 22 Nov 2024
TypeScript (94.27%)
JavaScript (5.73%)
Cumulative downloads
Total Downloads
Last day
47.2%
78
Compared to previous day
Last week
73.7%
521
Compared to previous week
Last month
0.1%
1,820
Compared to previous month
Last year
3,105.7%
14,554
Compared to previous year
1
7
WebdriverIO (wdio) service for running QUnit browser-based tests and dynamically converting them to wdio
test suites.
QUnit Service
is a drop-in replacement for those using Karma JS to run their QUnit
tests (karma-qunit, karma-ui5 or any other combination of Karma and QUnit). Karma is deprecated and people should move to modern alternatives!
If you want to keep your QUnit tests as they are, with no rewriting and no refactoring, QUnit Service
is everything you need. It runs your QUnit HTML files in a browser and captures all the results in wdio
format.
Because of that, developers can use QUnit Service
in tandem with everything else available in the wdio
ecosystem.
Want to record the test run in a video? Perhaps take a screenshot or save it in PDF? Check the Code coverage? Save the test results in JUnit format? Go for it, QUnit Service
doesn't get on your way.
After configuring WebdriverIO
, install wdio-qunit-service
as a devDependency in your package.json
file.
1npm install wdio-qunit-service --save-dev
If you haven't configured WebdriverIO
yet, check the official documentation out.
In order to use QUnit Service
you just need to add it to the services
list in your wdio.conf.js
file. The wdio documentation has all information related to the configuration file:
1// wdio.conf.js 2export const config = { 3 // ... 4 services: ["qunit"], 5 // ... 6};
Make sure the web server is up and running before executing the tests. wdio
will not start the web server.
In your WebdriverIO test, you need to navigate to the QUnit HTML test page, then call browser.getQUnitResults()
.
1describe("QUnit test page", () => { 2 it("should pass QUnit tests", async () => { 3 await browser.url("http://localhost:8080/test/unit/unitTests.qunit.html"); 4 await browser.getQUnitResults(); 5 }); 6});
It's recommended to have one WebdriverIO test file per QUnit HTML test page. This ensures the tests will run in parallel and fully isolated.
If you don't want to create spec/test files, you can pass a list of QUnit HTML files to the configuration and the tests will be automatically generated.
1// wdio.conf.js 2export const config = { 3 // ... 4 baseUrl: 'http://localhost:8080', 5 services: [ 6 ['qunit', { 7 paths: [ 8 'unit-tests.html', 9 'integration-tests.html', 10 'test/qunit.html' 11 ] 12 }], 13 // ... 14};
Test results could look like:
Check the examples folder out for samples using javascript
, typescript
and more.
Straight forward example using the well known openui5-sample-app:
Create a configuration file: wdio.conf.js
Tell wdio
where to find the QUnit test files:
The web server must be running before executing the tests
Run it $ wdio run ./webapp/test/wdio.conf.js
Mauricio Lauffer
This project is licensed under the MIT License - see the LICENSE file for details.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
17 out of 17 merged PRs checked by a CI test -- score normalized to 10
Reason
no dangerous workflow patterns detected
Reason
update tool detected
Details
Reason
license file detected
Details
Reason
10 commit(s) and 2 issue activity found in the last 90 days -- score normalized to 10
Reason
security policy file detected
Details
Reason
SAST tool is not run on all commits -- score normalized to 9
Details
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
branch protection is not maximal on development and all release branches
Details
Reason
4 existing vulnerabilities detected
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
Found 0/24 approved changesets -- score normalized to 0
Reason
project has 0 contributing companies or organizations -- score normalized to 0
Reason
project is not fuzzed
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Score
Last Scanned on 2024-11-25T05:31:27Z
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More