Skip to content

Commit

Permalink
Use React 19 in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
wojtekmaj committed May 8, 2024
1 parent a204716 commit c15279d
Showing 1 changed file with 28 additions and 4 deletions.
32 changes: 28 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,11 @@ jobs:
run: yarn lint

typescript:
name: Type checking
name: Type checking (React ${{ matrix.react }})
runs-on: ubuntu-latest
strategy:
matrix:
react: [18, 19]

steps:
- name: Checkout
Expand All @@ -74,10 +77,19 @@ jobs:
- name: Install dependencies
run: yarn --immutable

- name: Override React version
if: ${{ matrix.react == 19 }}
run: |
yarn up react@beta react-dom@beta
npm pkg set resolutions.'@types/react'='npm:types-react@beta'
npm pkg set resolutions.'@types/react-dom'='npm:types-react-dom@beta'
yarn config set enableImmutableInstalls false
yarn
- name: Build package
run: yarn build

- name: Run type checking
- name: Run type checking (React ${{ matrix.react }})
run: yarn tsc

format:
Expand Down Expand Up @@ -113,8 +125,11 @@ jobs:
run: yarn format

unit:
name: Unit tests
name: Unit tests (React ${{ matrix.react }})
runs-on: ubuntu-latest
strategy:
matrix:
react: [18, 19]

steps:
- name: Checkout
Expand All @@ -141,5 +156,14 @@ jobs:
- name: Install dependencies
run: yarn --immutable

- name: Run tests
- name: Override React version
if: ${{ matrix.react == 19 }}
run: |
yarn up react@beta react-dom@beta
npm pkg set resolutions.'@types/react'='npm:types-react@beta'
npm pkg set resolutions.'@types/react-dom'='npm:types-react-dom@beta'
yarn config set enableImmutableInstalls false
yarn
- name: Run tests (React ${{ matrix.react }})
run: yarn unit

0 comments on commit c15279d

Please sign in to comment.