Skip to content

Bump actions/setup-node from 4 to 6 #653

Bump actions/setup-node from 4 to 6

Bump actions/setup-node from 4 to 6 #653

Workflow file for this run

name: CI
on:
push:
branches:
- main
tags: "*"
pull_request:
workflow_dispatch:
concurrency:
# Skip intermediate builds: always.
# Cancel intermediate builds: only if it is a pull request build.
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ github.event_name }}
runs-on: ${{ matrix.os }}
timeout-minutes: 60
permissions:
# needed to allow julia-actions/cache to proactively delete old caches that it has created
actions: write
contents: read
strategy:
fail-fast: false
matrix:
version:
- "1.10"
- "1"
os:
- ubuntu-latest
- macOS-latest
- windows-latest
steps:
- uses: actions/checkout@v6
- uses: julia-actions/setup-julia@v3
with:
version: ${{ matrix.version }}
- uses: julia-actions/cache@v3
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
env:
JULIA_NUM_THREADS: 4
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v6
with:
files: lcov.info
docs:
name: Documentation
runs-on: ubuntu-latest
permissions:
actions: write # needed to allow julia-actions/cache to proactively delete old caches that it has created
contents: write
statuses: write
steps:
- uses: actions/checkout@v6
- uses: julia-actions/setup-julia@v3
with:
version: "1"
- uses: julia-actions/cache@v3
- name: Configure doc environment
shell: julia --project=docs --color=yes {0}
run: |
using Pkg
Pkg.develop(PackageSpec(path=pwd()))
Pkg.instantiate()
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-docdeploy@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
- name: Run doctests
shell: julia --project=docs --color=yes {0}
run: |
using Documenter: DocMeta, doctest
using PlantSimEngine
DocMeta.setdocmeta!(PlantSimEngine, :DocTestSetup, :(using PlantSimEngine); recursive=true)
doctest(PlantSimEngine)
graph-editor-e2e:
name: Graph editor E2E
runs-on: ubuntu-latest
timeout-minutes: 30
permissions:
actions: write
contents: read
steps:
- uses: actions/checkout@v6
- uses: julia-actions/setup-julia@v3
with:
version: "1"
- uses: julia-actions/cache@v3
- name: Configure test environment
shell: julia --project=test --color=yes {0}
run: |
using Pkg
Pkg.develop(PackageSpec(path=pwd()))
Pkg.instantiate()
- uses: actions/setup-node@v6
with:
node-version: "22"
cache: npm
cache-dependency-path: frontend/package-lock.json
- name: Install frontend dependencies
working-directory: frontend
run: npm ci
- name: Run frontend unit tests
working-directory: frontend
run: npm test
- name: Typecheck graph editor frontend
working-directory: frontend
run: npm run typecheck
- name: Build graph editor frontend
working-directory: frontend
run: npm run build
- name: Check committed graph editor assets
run: |
git diff --exit-code -- frontend/dist || {
echo "frontend/dist is stale. Run npm run build in frontend/ and commit the rebuilt assets.";
exit 1;
}
- name: Install Playwright browser
working-directory: frontend
run: npx playwright install --with-deps chromium
- name: Run graph editor E2E tests
working-directory: frontend
run: npm run test:e2e
- name: Upload Playwright artifacts
if: failure()
uses: actions/upload-artifact@v4
with:
name: graph-editor-playwright-artifacts
path: |
frontend/playwright-report/
frontend/test-results/