-
-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (43 loc) · 1.03 KB
/
observer-tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: Test Observer
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: postgres
POSTGRES_DB: observer_test
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
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.11
uses: actions/setup-python@v3
with:
python-version: "3.11"
- name: Install dependencies
run: |
pip install --upgrade pip poetry
poetry install
- name: Lint
run: |
poetry run make lint
- name: Test
run: |
poetry run pytest --trace tests -vvv
env:
DB_URI: postgresql+asyncpg://postgres:postgres@localhost:5432/observer_test