In this article let's discuss the integration of CI/CD BitBucket with Playwright to perform end-to-end testing using Bitbucket and Playwright.
Step 1: Create BitBucket Repo if required or go to your project root
Step 2: Create yml file with name bitbucket-pipelines.yml in project root directory

Step 3: Paste below code
pipelines:
default:
- step:
name: Playwright Tests
image: mcr.microsoft.com/playwright
script:
- npm ci
# - Run the test cases
- npx playwright test --config=playwright.config.ts
artifacts:
- playwright-report/index.html
Here,
- image: your docket image value
- config path: change accordingly
- artifacts: Your report path
Step 4: Run pipeline using any of method
- Push Code: Once your will push your code build will trigger
- Run Pipeline Option: Find it on BitBucket Interface
- Scheduling: Find it on BitBucket Interface
Step 5: Download and View Report by clicking on Pipelines -> Artifacts
