Skip to content

Commit

Permalink
Create test-and-lint.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
steezeburger committed May 24, 2024
1 parent 3926236 commit a1a1c80
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/test-and-lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Test and Lint

on:
pull_request:
push:
branches:
- "main"

jobs:
test-and-lint-front-end:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./web
steps:
- uses: actions/checkout@master
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: 18
- uses: actions/cache@v4
id: cache-node-modules
with:
path: "web/node_modules"
key: ${{ runner.os }}-modules-${{ hashFiles('web/package-lock.json') }}
- name: Install Dependencies
if: steps.cache-node-modules.outputs.cache-hit != 'true'
run: npm install
- name: Copy env file
run: cp .env.example .env
- name: Lint
run: npm run lint
- name: Test
run: CI=true npm run test

0 comments on commit a1a1c80

Please sign in to comment.