Skip to content
This repository has been archived by the owner on Aug 11, 2024. It is now read-only.

Add .env.testing

Add .env.testing #4

Workflow file for this run

name: Tests Pipeline
on:
push:
branches: [ "develop" ]
pull_request:
branches: [ "develop" ]
jobs:
build:
name: Tests Pipeline (Python ${{ matrix.python-version }})
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
python-version: [3.11]
services:
mysql:
image: mysql:5.7
env:
MYSQL_ROOT_PASSWORD: 'secret'
MYSQL_DATABASE: 'boilerplate'
MYSQL_USER: 'user'
MYSQL_PASSWORD: 'secret'
ports:
- 3306/tcp
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
redis:
image: redis
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 6379:6379
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
pip install -r requirements.txt
- name: Create environment file
run: cp .env.testing .env
- name: Run Tests
run: |
python manage.py test