diff --git a/README.md b/README.md index 2ef53b6..754ca15 100644 --- a/README.md +++ b/README.md @@ -73,4 +73,4 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d -This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome! +This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome! \ No newline at end of file diff --git a/testing/src/main/java/io/quarkiverse/playwright/QuarkusPlaywrightManager.java b/testing/src/main/java/io/quarkiverse/playwright/QuarkusPlaywrightManager.java index 97385e1..d60ddd8 100644 --- a/testing/src/main/java/io/quarkiverse/playwright/QuarkusPlaywrightManager.java +++ b/testing/src/main/java/io/quarkiverse/playwright/QuarkusPlaywrightManager.java @@ -64,15 +64,11 @@ public Map start() { } private static BrowserType browser(Playwright playwright, WithPlaywright.Browser browser) { - switch (browser) { - case CHROMIUM: - return playwright.chromium(); - case FIREFOX: - return playwright.firefox(); - case WEBKIT: - return playwright.webkit(); - } - return playwright.chromium(); + return switch (browser) { + case FIREFOX -> playwright.firefox(); + case WEBKIT -> playwright.webkit(); + default -> playwright.chromium(); + }; } @Override @@ -97,4 +93,4 @@ public void inject(TestInjector testInjector) { new TestInjector.AnnotatedAndMatchesType(InjectPlaywright.class, Browser.class)); } -} +} \ No newline at end of file