Skip to content

Latest commit

 

History

History
94 lines (76 loc) · 2.76 KB

CONTRIBUTING.md

File metadata and controls

94 lines (76 loc) · 2.76 KB

Contributing to Playwright-BDD

Thank you for considering contributing to Playwright-BDD! 🎉
This guide will help you get started with contributing.

How Can I Contribute?

There are different ways to contribute.

Showcase Your Expertise

We encourage you to share your experiences and insights about using Playwright-BDD! BDD workflows can vary widely, and your unique approach could inspire others in the community.

Here are some ways to share your knowledge:

  • Write articles on platforms like Dev.to, Medium, or LinkedIn.
  • Share interesting findings, tips, and best practices related to Playwright-BDD or end-to-end testing in general.
  • Promote your content on the Playwright Discord articles and your social networks to reach a broader audience.

By contributing to the conversation, you'll help grow the Playwright-BDD community and improve testing workflows for everyone!

Create Bug Reports and Feature Requests

If you find a bug or have an idea for a feature:

  1. Check if the issue already exists in the Issues.
  2. If not, create a new issue!

Contribute Code

To contribute code:

  1. Fork the playwright-bdd repository.
  2. Clone your fork to your local machine:
    git clone https://github.com/<YOUR_USERNAME>/playwright-bdd.git
  3. Create a new branch for your feature or bug fix:
    git checkout -b my-feature
  4. Perform the development setup
  5. Make and commit your changes.
  6. Push the changes to your fork:
    git push origin my-feature
  7. Open a pull request to the main branch.

Development Setup

  1. Install dependencies:
    cd playwright-bdd
    npm install
    
  2. Install Playwright browsers:
    npx playwright install chromium
    
  3. Run tests:
    npm t
    

Useful Dev Commands

Run a Single Test

Use the command below (use TAB after typing test/ to autocomplete the test path):

npm run only test/<%test-dir%>

Example:

npm run only test/special-tags

Switch Playwright Version

This command will install the provided Playwright version without saving it to package.json:

npx cross-env PW=1.45 npm run pw

Install Playwright Browsers

This command will install chromium for the current Playwright version, without clearing previous browsers:

npm run pw:browsers

Check Deprecated Playwright Versions

npm show @playwright/test@1 deprecated

Clear Playwright Compilation Cache

npx playwright clear-cache