Skip to content

Version Packages

Version Packages #9745

Workflow file for this run

name: Test
on:
push:
branches:
- master
pull_request:
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x, 16.x, 18.x]
steps:
- uses: actions/checkout@v3
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Set ignore engines
run: yarn config set ignore-engines true
- uses: actions/cache@v3
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install packages
run: yarn
- name: Validate
run: yarn lint
- name: Check prettier
run: yarn prettier:check
- name: Bundle size
run: |
GITHUB_RUN_NUMBER_TMP=GITHUB_RUN_NUMBER && export GITHUB_RUN_NUMBER=1;
echo "$GITHUB_RUN_NUMBER"
yarn bundlesize
export GITHUB_RUN_NUMBER=GITHUB_RUN_NUMBER_TMP
echo "$GITHUB_RUN_NUMBER"
- name: Build source for remainder tests
run: yarn build
# Needs to run after `yarn build` so that `packages/webpack-loader/`
# tests can resolve `@compiled/react/runtime` correctly.
- name: Run tests
run: yarn test:cover --ci
- name: Run import test
run: yarn test:imports
- name: Run parcel tests
run: yarn test:parcel