From fd1f32556bfe7d39fa842f925b6fcc9d2edf56cc Mon Sep 17 00:00:00 2001 From: Yury Semikhatsky Date: Wed, 11 Sep 2024 14:24:32 -0700 Subject: [PATCH] chore: run all tests with bidi by default (#32572) Only use expectation files on CI to save resources --- .github/workflows/tests_bidi.yml | 2 ++ tests/bidi/expectationUtil.ts | 2 ++ 2 files changed, 4 insertions(+) diff --git a/.github/workflows/tests_bidi.yml b/.github/workflows/tests_bidi.yml index b534a7b747..8224d24883 100644 --- a/.github/workflows/tests_bidi.yml +++ b/.github/workflows/tests_bidi.yml @@ -42,3 +42,5 @@ jobs: if: matrix.channel == 'bidi-firefox-beta' - name: Run tests run: xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" -- npm run biditest -- --project=${{ matrix.channel }}* + env: + PWTEST_USE_BIDI_EXPECTATIONS: '1' diff --git a/tests/bidi/expectationUtil.ts b/tests/bidi/expectationUtil.ts index ce55416048..23491d2d91 100644 --- a/tests/bidi/expectationUtil.ts +++ b/tests/bidi/expectationUtil.ts @@ -23,6 +23,8 @@ export type TestExpectation = 'unknown' | 'flaky' | 'pass' | 'fail' | 'timeout'; type ShouldSkipPredicate = (info: TestInfo) => boolean; export async function createSkipTestPredicate(projectName: string): Promise { + if (!process.env.PWTEST_USE_BIDI_EXPECTATIONS) + return () => false; const expectationsMap = await parseBidiExpectations(projectName); return (info: TestInfo) => { const key = [info.project.name, ...info.titlePath].join(' › ');