Skip to content

New authentication provider with tests #8

New authentication provider with tests

New authentication provider with tests #8

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
lint-and-typecheck:
name: Lint & Type Check
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"
- name: Install dependencies
run: npm ci
- name: Type check
run: npx tsc --noEmit
unit-tests:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"
- name: Install dependencies
run: npm ci
- name: Run unit tests
run: npm run test:run
- name: Upload coverage
uses: actions/upload-artifact@v4
if: always()
with:
name: coverage-report
path: coverage/
retention-days: 7
build:
name: Build
runs-on: ubuntu-latest
env:
NEXT_PUBLIC_BACKEND_URL: http://localhost:8080
NEXT_PUBLIC_BETTER_AUTH_URL: http://localhost:8082/auth
NEXT_PUBLIC_DASHBOARD_HOME_PAGE: /dashboard/flowsheet
NEXT_PUBLIC_VERSION: ci
NEXT_PUBLIC_DEFAULT_EXPERIENCE: modern
NEXT_PUBLIC_ENABLED_EXPERIENCES: modern,classic
NEXT_PUBLIC_ALLOW_EXPERIENCE_SWITCHING: "true"
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build