Skip to content

Pes 1073 v2 enable slack digestion #60

Pes 1073 v2 enable slack digestion

Pes 1073 v2 enable slack digestion #60

Workflow file for this run

name: Run unit tests
on:
push:
branches: [develop]
pull_request:
jobs:
build:
runs-on: ubuntu-latest
services:
postgres:
image: postgres:13
env:
POSTGRES_DB: incident_bot
POSTGRES_USER: incident_bot
POSTGRES_PASSWORD: somepassword
POSTGRES_PORT: 5432
ports:
- 5432:5432
# Set health checks to wait until postgres has started
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
timeout-minutes: 10
strategy:
matrix:
python-version: ['3.11']
env:
# default: multiprocessing
# threading is more stable on GitHub Actions
BOLT_PYTHON_MOCK_SERVER_MODE: threading
defaults:
run:
working-directory: backend
steps:
- uses: actions/checkout@v2
- name: Pull credential file
env:
GOOGLE_HANGOUT_CREDS: ${{ secrets.GOOGLE_HANGOUT_CREDS }}
run: |
sudo mkdir /config
sudo chmod -R 777 /config
sudo echo "$GOOGLE_HANGOUT_CREDS" > /config/google-creds.json
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
pip3 install -r requirements.txt
pip3 install "pytest>=7.1.2"
pip3 install "pytest-mock>=3.10.0"
pip3 install "pytest-env>=0.8.1"
- name: Run tests
env:
GOOGLE_SERVICE_ACCOUNT_SECRET: ${{ secrets.GOOGLE_SERVICE_ACCOUNT_SECRET }}
GOOGLE_ACCOUNT_EMAIL: ${{ secrets.GOOGLE_ACCOUNT_EMAIL }}
run: |
pytest -vv tests/