web-extensions/
├── packages/
│ ├── web-app-.../ // Tests for the specific web application
│ │ ├── tests/
│ │ │ ├── e2e/ // e2e tests for the application
│ │ │ ├── unit/ // unit tests for the application
├── support/ // Supporting files for tests (helpers, page objects, etc.)
│ ├── helpers/ // Helper functions and utilities
│ │ ├── authHelper.ts
│ │ ├── ...
│ ├── pages/ // Page Object Model (POM) files
│ │ ├── loginPage.ts
│ │ ├── ...
├── playwright.config.js // Playwright configuration file
This Playwright configuration defines multiple projects for testing web applications in different browsers. Each project is assigned its own set of browsers, and the configuration includes settings for parallel test execution, retries, and reporting.
Draw-IO Tests:
- Chromium: Tests for Draw-IO app using the Chromium browser.
- Firefox: Tests for Draw-IO app using the Firefox browser.
- WebKit: Tests for Draw-IO app using the Safari WebKit browser.
Install Playwright Extension for VSCode
$ pnpm test:e2e
$ pnpm test:e2e --project="draw-io-chromium"
$ pnpm test:e2e --project="draw-io-chromium" packages/web-app-draw-io --headed
$ pnpm test:e2e --project="draw-io-chromium" packages/web-app-draw-io/tests/e2e/createDrawIo.spec.ts