Skip to content

Commit 3d93f03

Browse files
LipataCopilot
andauthored
ci(react): install playwright in the yaml file (#1450)
* ci: install Playwright in the YAML file * Update packages/cli/templates/react/igr-ts/projects/_base/files/__dot__github/workflows/node.js.yml Co-authored-by: Copilot <[email protected]> * Update packages/cli/templates/react/igr-ts/projects/_base/files/__dot__azure/azure-pipelines.yml Co-authored-by: Copilot <[email protected]> * ci(react): add env to test step --------- Co-authored-by: Copilot <[email protected]>
1 parent a5e0289 commit 3d93f03

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

packages/cli/templates/react/igr-ts/projects/_base/files/__dot__azure/azure-pipelines.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,9 @@ steps:
1919
continueOnError: true
2020
- script: npm run build
2121
displayName: 'Build the project'
22+
- script: npx playwright install chromium-headless-shell
23+
displayName: 'Install Playwright browsers'
2224
- script: npm run test
2325
displayName: 'Run tests'
26+
env:
27+
CI: 'true'

packages/cli/templates/react/igr-ts/projects/_base/files/__dot__github/workflows/node.js.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,5 +29,8 @@ jobs:
2929
- run: npm i # replace with 'npm ci' after committing lock file from first install
3030
# - run: npm run lint
3131
- run: npm run build
32+
- name: Install Playwright browsers
33+
run: npx playwright install chromium-headless-shell
3234
- run: npm run test
33-
35+
env:
36+
CI: 'true'
Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
1-
import '@testing-library/jest-dom'
21
import 'vitest-canvas-mock'
32
import ResizeObserver from 'resize-observer-polyfill'
43
import {vi} from 'vitest'
54

6-
global.ResizeObserver = ResizeObserver;
5+
globalThis.ResizeObserver = ResizeObserver;
76

87
HTMLElement.prototype.scrollIntoView = vi.fn();
98
HTMLElement.prototype.hidePopover = vi.fn();
109
HTMLElement.prototype.showPopover = vi.fn();
11-
HTMLElement.prototype.togglePopover = vi.fn();
10+
HTMLElement.prototype.togglePopover = vi.fn();

0 commit comments

Comments
 (0)