Automated end-to-end tests for Ecommerce demo store using Playwright.
pages/
— Page Object Modelstests/
— Test specificationsplaywright.config.js
— Playwright configurationplaywright-report/
— HTML and JSON test reports.github/workflows/test.yml
— CI/CD pipeline
npm install
If you haven't installed browsers yet:
npx playwright install
Run all tests:
npx playwright test
View the HTML report:
npx playwright show-report
Reports are generated in playwright-report/
. When integrating with Testdino, ensure both HTML and JSON reporters are enabled in playwright.config.js
.
Example reporter configuration:
reporter: [
['html', { outputFolder: 'playwright-report', open: 'never' }],
['json', { outputFile: './playwright-report/report.json' }],
]
Testdino enables cloud-based Playwright reporting.
Important:
Make sure yourplaywright.config.js
includes both the HTML and JSON reporters.
The HTML report and JSON report must be available for Testdino to process your test results.
Example configuration:
reporter: [
['html', { outputFolder: 'playwright-report', open: 'never' }],
['json', { outputFile: './playwright-report/report.json' }],
]
After your tests complete and the report is generated in playwright-report
, upload it to Testdino:
npx --yes tdpw ./playwright-report --token="YOUR_TESTDINO_API_KEY" --upload-html
Replace the token above with your own Testdino API key.
See all available commands:
npx tdpw --help
Add the following step to your workflow after tests and report generation:
- name: Send Testdino report
run: |
npx --yes tdpw ./playwright-report --token="YOUR_TESTDINO_API_KEY" --upload-html
Ensure your API key is correctly placed in the command.
Automated test runs and report merging are configured in .github/workflows/test.yml
.
Pull requests and issues are welcome!
MIT