Skip to content

Add postgres server to github action #47

Add postgres server to github action

Add postgres server to github action #47

Workflow file for this run

name: Test
on:
push:
jobs:
test:
runs-on: ubuntu-latest
services:
postgres:
image: postgres
env:
POSTGRES_HOST_AUTH_METHOD: trust
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10"]
env:
PGUSER: postgres
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: pip install ".[dev]"
- name: Test with pytest
run: pytest tests