fix playwright service createSnapshotBrowser

This commit is contained in:
Francis Cao committed 2026-05-27 16:00:28 -07:00
1 parent 39ef9a757b
commit c3cddcb774
3 files changed
+6 -62

No files matched your search

@@ -578,13 +578,14 @@ function getSnapshotErrorMessage(error: unknown) {
}
async function createSnapshotBrowser() {
const { chromium } = await import('@playwright/test');
const endpoint = process.env.PLAYWRIGHT_URL?.trim();
if (endpoint) {
const { chromium } = await import('playwright-core');
return chromium.connect(endpoint);
}
const { chromium } = await import('@playwright/test');
return chromium.launch({
channel: 'chromium',
headless: true,