Skip to content

react-experiment: fix render error msgs in tests (#221) #386

react-experiment: fix render error msgs in tests (#221)

react-experiment: fix render error msgs in tests (#221) #386

Workflow file for this run

# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
name: Node.js CI
on:
push:
branches: ['main']
pull_request:
branches: ['main']
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Node.js 20.x.x
uses: actions/setup-node@v4
with:
node-version: 20.x.x
- name: Install pnpm
uses: pnpm/action-setup@v2
id: pnpm-install
with:
run_install: false
- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v4
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- run: pnpm install --frozen-lockfile
- run: pnpm run build-all
- uses: actions/upload-artifact@v4
with:
name: 'build'
path: 'packages/*/dist/'
test:
needs: ['build']
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Node.js 20.x.x
uses: actions/setup-node@v4
with:
node-version: 20.x.x
- name: Install pnpm
uses: pnpm/action-setup@v2
id: pnpm-install
with:
run_install: false
- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v4
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- run: pnpm install --frozen-lockfile
- uses: actions/download-artifact@v4
id: download
with:
name: 'build'
path: 'packages'
- run: pnpm run test-all
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Node.js 20.x.x
uses: actions/setup-node@v4
with:
node-version: 20.x.x
- name: Install pnpm
uses: pnpm/action-setup@v2
id: pnpm-install
with:
run_install: false
- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v4
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- run: pnpm install --frozen-lockfile
- run: pnpm run lint
publint:
needs: ['build']
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Node.js 20.x.x
uses: actions/setup-node@v4
with:
node-version: 20.x.x
- name: Install pnpm
uses: pnpm/action-setup@v2
id: pnpm-install
with:
run_install: false
- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v4
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- run: pnpm install --frozen-lockfile
- uses: actions/download-artifact@v4
id: download
with:
name: 'build'
path: 'packages'
- run: pnpm run publint