Rayrun
← Back to Discord Forum

How to exclude a specific project in playwright.config.ts from sharding

Hello! In my playwright.config.ts, I have two projects set up for sharding in GitHub Actions. I've added a third project, but I'd like to exclude it from sharding. Does anyone know how to achieve this?

This thread is trying to answer question "How to exclude a specific project in playwright.config.ts from sharding?"

4 replies

Hm, say you're running npx playwright test --shard=1/2 on actions. What is your expectation regarding 3rd project? That it shouldn't run any tests from 3rd project?

We are using matrix to run sharding, playwright.yml: strategy: fail-fast: false matrix: shard: [1/6, 2/6, 3/6, 4/6, 5/6, 6/6]

as for my third project it i don't want it to use the above and instead run in a single shard

Aha, not easily doable I would say. You will probably need two run two commands, with one running two projects and sharding and the second will run just 3rd project.

makes sense thanks! I will try it

TwitterGitHubLinkedIn
AboutQuestionsDiscord ForumBrowser ExtensionTagsQA Jobs

Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email luc@ray.run.