Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: UI Mode - Set number of workers in ui mode interface #30304

Open
Kumasta opened this issue Apr 9, 2024 · 2 comments
Open

[Feature]: UI Mode - Set number of workers in ui mode interface #30304

Kumasta opened this issue Apr 9, 2024 · 2 comments

Comments

@Kumasta
Copy link

Kumasta commented Apr 9, 2024

馃殌 Feature Request

In the UI mode window - add a worker count and have the ability to set number of workers when running tests in UI mode.

Example

image

Add a worker count that can be adjusted in ui mode.

Motivation

I occasionally want to run tests with just one worker to test stability of tests one by one as well as some tests are run in a single context back to back.

I would need to close ui mode and add the worker flag to the command prompt to update this.

@HamzaMiz
Copy link

+1

@ssloanRIIS
Copy link

I support this.

What I'd also like to see, is workers based off of the project. I want to run most of my tests locally in parallel, but some of my tests NEED to be ran in serial. I would imagine that I could configure this per project, but it seems that I'm limited to only setting the amount of workers in the PlaywrightTestConfig rather than the project.

export default defineConfig({
  testDir: "./tests",
  fullyParallel: true,
  workers: 2,
  retries: 0,
  reporter: [["html"], ["list"]],

  use: {
    baseURL: process.env.BASE_URL || "http://localhost:3000",
    trace: "on-first-retry",
  },

  projects: [
    {
      name: "extra_secret_tests",
      fullyParallel: false, //<------- Disables *IN THE TEST FILE* but not in the suite...
      testDir: "./tests/extra_secret_tests",
      workers: 1, //<------ Why doesn't this work!!
      use: {
        ...devices["Desktop Chrome"],
        viewport: { width: 1920, height: 1080 },
        storageState: STORAGE_STATE,
      },
    },
  ],
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants