hackforla / peopledepot

A project to setup a datastore for people and projects at HackforLA. The link below takes you to the code documentation
https://hackforla.github.io/peopledepot/
GNU General Public License v2.0
5 stars 24 forks source link

Add testing to ci #344

Open fyliu opened 5 days ago

fyliu commented 5 days ago

Overview

We need to run pytest in ci so that we know PRs aren't broken.

Action Items

Resources/Instructions

Maybe something like this

on: push: branches: [ main ] pull_request: branches: [ main ] workflow_dispatch:

jobs: test: runs-on: ubuntu-latest

steps:
  - name: Check out project
    uses: actions/checkout@v3

  - name: Set up Python
    uses: actions/setup-python@v3
    with:
      python-version: '3.x'

  - name: Install dependencies
    run: cd app/ || pip3 install -r requirements.txt

  - name: Execute tests
    run: cd app/ || python3 -m pytest -v
fyliu commented 5 days ago

Looks like this could take a while. The project needs to be made runnable by itself, more so than @ethanstrominger's start-local.sh script does it, apparently.