question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Feature] Have critical section support for tests so projects don't run them in parallel

See original GitHub issue

can I limit workers to 1 on a single test file? - so as to not run the test suite sequentially I have my default projects set to 3 browsers to support multi-browser tests on a single run. I have a test case that has access to a resource that cannot be shared across the 3 browsers simultaneously. In order to avoid this race condition, I had to run this test on a single worker - so all three browsers don’t run in parallel. I tried making the test file serial by test.describe.configure({ mode: 'serial' }); and test.describe.serial(title, callback) but none of them had any effect on running the test serially across the 3 browsers. I assume the playwright doesn’t support serializing the test on a project level.

`projects: [ { name: ‘chromium’, use: { …devices[‘Desktop Chrome’], }, },

{
  name: 'firefox',
  use: {
    ...devices['Desktop Firefox'],
  },
},

{
  name: 'webkit',
  use: {
    ...devices['Desktop Safari'],
  },
},`

Issue Analytics

  • State:open
  • Created a year ago
  • Reactions:4
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
ltsudacommented, May 11, 2022

Please, see link below, maybe it could help.

https://playwright.dev/docs/test-parallel#disable-parallelism

Read more comments on GitHub >

github_iconTop Results From Across the Web

Critical Sections | TestComplete Documentation
A critical section is a specific marked part of a test which can only be performed by one project at a time. That...
Read more >
What is Parallel Execution? - Functionize
In simple terms, parallel execution is a means to test multiple applications or multiple components of an application at the same time. This ......
Read more >
GitHub Actions Parallel Test Automation Jobs - Testmo
Our complete guide to GitHub Actions parallel testing jobs. Improve test automation execution & performance by running parallel testing jobs and speed up ......
Read more >
OpenMP Critical Sections - Intel
Critical sections are useful for a non-nested mutex. Unlike OpenMP atomic operations that provide fine-grain synchronization for a single operation, critical ...
Read more >
How to execute cucumber feature file parallel - Stack Overflow
The tags to run, maps to CucumberOptions.tags property you can pass ... die if it doesn't get enough memory therefore to avoid this...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found