Skip to content

feat: New Courses View #467

feat: New Courses View

feat: New Courses View #467

Workflow file for this run

name: Backend Pull Request Check
env:
HUSKY: 0
# environment variables for testing
JWT_SECRET: "test_secret"
JWT_REFRESH_SECRET: "test_refresh"
JWT_EXPIRATION_TIME: "15min"
CORS_ORIGIN: ""
EMAIL_ADAPTER: "mailhog"
DATABASE_URL: ""
REDIS_URL: ""
SMTP_HOST: ""
SMTP_PORT: "1025"
SMTP_USER: ""
SMTP_PASSWORD: ""
AWS_REGION: "us-east-1"
AWS_ACCESS_KEY_ID: ""
AWS_SECRET_ACCESS_KEY: ""
AWS_BUCKET_NAME: ""
SES_EMAIL: "[email protected]"
STRIPE_SECRET_KEY: "test_secret"
STRIPE_PUBLISHABLE_KEY: "test_secret"
STRIPE_WEBHOOK_SECRET: "test_secret"
on:
pull_request:
branches:
- "*"
paths:
- apps/api/**
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v4
with:
node-version: 20.15.0
cache: pnpm
- name: Install dependencies
run: pnpm install
- name: Run ESLint
run: pnpm --filter=api lint-tsc
build:
name: Build app
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./apps/api/
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v4
with:
node-version: 20.15.0
cache: pnpm
- run: pnpm install
- name: Build the app
run: pnpm run build
test:
name: Jest tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- name: Start containers
run: docker compose -f "docker-compose.yml" up -d --build
- uses: actions/setup-node@v4
with:
node-version: 20.9.0
cache: pnpm
- name: Install dependencies
run: pnpm install
- name: Run unit tests
run: pnpm --filter=api test:ci
- name: Run e2e tests
run: pnpm --filter=api test:e2e