Skip to content

Commit 0f66814

Browse files
authored
utils.js: try different approach to running WebKit
... and removed unused `device` definition, should've been removed in the previous commit
1 parent 89a7462 commit 0f66814

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

packages/kit/test/utils.js

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import fs from 'fs';
22
import http from 'http';
33
import * as ports from 'port-authority';
4-
import { test as base, devices } from '@playwright/test';
4+
import { test as base } from '@playwright/test';
55

66
export const test = base.extend({
77
// @ts-expect-error
@@ -136,13 +136,6 @@ export const test = base.extend({
136136
}
137137
});
138138

139-
const useDesktopChrome = {
140-
browserName: 'chromium',
141-
// use stable chrome from host OS instead of downloading one
142-
// see https://playwright.dev/docs/browsers#google-chrome--microsoft-edge
143-
channel: 'chrome'
144-
};
145-
146139
/** @type {import('@playwright/test').PlaywrightTestConfig} */
147140
export const config = {
148141
forbidOnly: !!process.env.CI,
@@ -157,14 +150,12 @@ export const config = {
157150
{
158151
name: `${process.env.DEV ? 'dev' : 'build'}+js_chrome`,
159152
use: {
160-
use: useDesktopChrome,
161153
javaScriptEnabled: true
162154
}
163155
},
164156
{
165157
name: `${process.env.DEV ? 'dev' : 'build'}-js_chrome`,
166158
use: {
167-
use: useDesktopChrome,
168159
javaScriptEnabled: false
169160
}
170161
},
@@ -185,6 +176,9 @@ export const config = {
185176
],
186177
use: {
187178
screenshot: 'only-on-failure',
179+
// use stable chrome from host OS instead of downloading one
180+
// see https://playwright.dev/docs/browsers#google-chrome--microsoft-edge
181+
channel: 'chrome',
188182
trace: 'retain-on-failure'
189183
},
190184
workers: process.env.CI ? 2 : undefined

0 commit comments

Comments
 (0)