playwright-qase-reporter v1.2.2
Qase TMS Playwright reporter
Publish results simple and easy.
How to integrate
npm install playwright-qase-reporter
Example of usage
The Playwright reporter has the ability to auto-generate test cases and suites from your test data.
But if necessary, you can independently register the ID of already existing test cases from TMS before the executing tests. For example:
import { qase } from 'playwright-qase-reporter/playwright';
describe('Test suite', () => {
test(qase([1, 2], 'Several ids'), () => {
expect(true).toBe(true);
});
test(qase(3, 'Correct test'), () => {
expect(true).toBe(true);
});
test.skip(qase('4', 'Skipped test'), () => {
expect(true).toBe(true);
});
test(qase(['5', '6'], 'Failed test'), () => {
expect(true).toBe(false);
});
});
To run tests and create a test run, execute the command (for example from folder examples):
QASE_MODE=testops npx playwright test
or
npm test
A test run will be performed and available at:
https://app.qase.io/run/QASE_PROJECT_CODE
Configuration
Reporter options (* - required):
mode
-testops
/off
Enables reporter, default -off
debug
- Enables debug logging, defaule -false
environment
- To execute with the sending of the envinroment information- *
testops.api.token
- Token for API access, you can find more information here - *
testops.project
- Code of your project (can be extracted from main page of your project:https://app.qase.io/project/DEMOTR
-DEMOTR
is project code here) testops.uploadAttachments
- Permission to send screenshots to Qase TMStestops.run.id
- Pass Run IDtestops.run.title
- Set custom Run name, when new run is createdtestops.run.description
- Set custom Run description, when new run is createdtestops.run.complete
- Whether the run should be completed
Example playwright.config.js
config:
const config = {
use: {
screenshot: 'only-on-failure',
video: 'retain-on-failure',
},
reporter: [
['list'],
[
'playwright-qase-reporter',
{
debug: true,
testops: {
api: {
token: 'api_key',
},
project: 'project_code',
uploadAttachments: true,
run: {
complete: true,
},
},
},
],
],
};
module.exports = config;
You can check example configuration with multiple reporters in example project.
Supported ENV variables:
QASE_MODE
- Same asmode
QASE_DEBUG
- Same asdebug
QASE_ENVIRONMENT
- Same asenvironment
QASE_TESTOPS_API_TOKEN
- Same astestops.api.token
QASE_TESTOPS_PROJECT
- Same astestops.project
QASE_TESTOPS_RUN_ID
- Pass Run ID from ENV and override reporter optiontestops.run.id
QASE_TESTOPS_RUN_TITLE
- Same astestops.run.title
QASE_TESTOPS_RUN_DESCRIPTION
- Same astestops.run.description
Requirements
We maintain the reporter on LTS versions of Node. You can find the current versions by following the link
@playwright/test >= 1.16.3
7 days ago
8 days ago
23 days ago
24 days ago
29 days ago
29 days ago
1 month ago
1 month ago
1 month ago
1 month ago
1 month ago
1 month ago
5 months ago
8 months ago
8 months ago
9 months ago
1 year ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago