backend: APIs enabled for handling pet pictures #183
Workflow file for this run
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: Django Backend Unit Tests | |
on: | |
push: | |
branches: ["develop"] | |
pull_request: | |
branches: ["develop"] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
max-parallel: 4 | |
matrix: | |
python-version: [3.8, 3.9] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v3 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install Dependencies | |
run: | | |
python -m pip install --upgrade pip | |
cd furbaby | |
pip install -r requirements.txt | |
- name: Check Format | |
run: | | |
black . | |
- name: Check Link | |
run: | | |
pylint **/*.py --exit-zero | |
- name: Run Tests | |
run: | | |
cd furbaby | |
export AWS_RDS_DATABASE_PASSWORD="dummy-password" | |
export DJANGO_SECRET_KEY="dummy-secret-key" | |
export EMAIL_APP_PASSWORD="dummy-user-email-password" | |
export EMAIL_APP_USERNAME="dummy-user-email" | |
export AWS_ACCESS_KEY_ID="dummy-user-key-id" | |
export AWS_SECRET_ACCESS_KEY="dummy-secret-access-key" | |
export AWS_BUCKET_NAME="dummy-aws-bucket-name" | |
python manage.py test |