From d477a79e64b5d90b07c48823244213c88cdd8f0a Mon Sep 17 00:00:00 2001 From: Cezar Augusto Date: Sat, 7 Dec 2024 10:47:43 -0300 Subject: [PATCH] Fix build spec --- examples/new/template.spec.ts | 7 ++++--- programs/develop/build.spec.ts | 16 +++++++++------- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/examples/new/template.spec.ts b/examples/new/template.spec.ts index 2868182f..6edee971 100644 --- a/examples/new/template.spec.ts +++ b/examples/new/template.spec.ts @@ -16,9 +16,10 @@ test('should exist an element with the welcome message text', async ({ page }) => { await page.goto('chrome://newtab/') - - const h1 = await page.waitForSelector('h1', {state: 'visible', timeout: 5000}) - + const h1 = await page.waitForSelector('h1', { + state: 'visible', + timeout: 10000 + }) const textContent = await h1.textContent() test.expect(textContent).toMatch(/Welcome to your/i) }) diff --git a/programs/develop/build.spec.ts b/programs/develop/build.spec.ts index ed28a163..a7a7a6e5 100644 --- a/programs/develop/build.spec.ts +++ b/programs/develop/build.spec.ts @@ -121,13 +121,15 @@ describe('extension build', () => { 'content_scripts/content-0.js' ) - expect( - distFileExists( - template.name, - SUPPORTED_BROWSERS[0], - 'content_scripts/content-0.css' - ) - ).toBeTruthy() + // Since extension@2.0.0-beta-6, the content script is injected + // into the shadow DOM. Including in production mode. + // expect( + // distFileExists( + // template.name, + // SUPPORTED_BROWSERS[0], + // 'content_scripts/content-0.css' + // ) + // ).toBeTruthy() expect( distFileExists(