35 lines
992 B
YAML
35 lines
992 B
YAML
name: CI
|
|
on:
|
|
pull_request:
|
|
jobs:
|
|
build-and-deploy:
|
|
runs-on: ubuntu-latest
|
|
permissions: write-all
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@master
|
|
- name: Install pnpm
|
|
run: npm i -g pnpm@9.0.4
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 18
|
|
# cache: "pnpm"
|
|
- run: pnpm install
|
|
- run: pnpm check-build
|
|
- run: pnpm test-unit
|
|
- run: pnpm lint
|
|
- run: pnpm tsx scripts/buildNpmReact.ts
|
|
- run: nohup pnpm prod-start &
|
|
- run: nohup pnpm test-mc-server &
|
|
- uses: cypress-io/github-action@v5
|
|
with:
|
|
install: false
|
|
- uses: actions/upload-artifact@v3
|
|
if: failure()
|
|
with:
|
|
name: cypress-images
|
|
path: cypress/integration/__image_snapshots__/
|
|
- run: node scripts/outdatedGitPackages.mjs
|
|
if: github.ref == 'refs/heads/next'
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|