[pre-commit.ci] pre-commit autoupdate #283
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: | |
- 'main' | |
tags: | |
- 'v*' | |
- '!*dev*' | |
- '!*pre*' | |
- '!*post*' | |
pull_request: | |
# Allow manual runs through the web UI | |
workflow_dispatch: | |
# Cancel old jobs if new jobs start | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
backend: | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
working-directory: ./backend | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Install Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.9 | |
- uses: actions/checkout@v3 | |
- name: Setup redis | |
uses: shogo82148/actions-setup-redis@v1 | |
- name: Update pip | |
run: python -m pip install -U pip | |
- name: Install pytest | |
run: python -m pip install -U pytest | |
- name: Install backend requirements | |
run: python -m pip install -r requirements.txt | |
- name: Run pytest | |
run: pytest . | |
frontend: | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
working-directory: ./frontend | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Use Node.js | |
uses: actions/[email protected] | |
- name: Run npm install | |
run: npm install | |
- name: Run tests | |
run: npm run test -- --coverage |