Skip to content

Commit 00c7509

Browse files
committed
test: New workflow for sqlc-gen-python
1 parent c19358b commit 00c7509

File tree

1 file changed

+9
-29
lines changed

1 file changed

+9
-29
lines changed

.github/workflows/ci-python.yml

Lines changed: 9 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -10,35 +10,15 @@ jobs:
1010
name: test
1111
runs-on: ubuntu-latest
1212

13-
services:
14-
postgres:
15-
image: postgres:11
16-
env:
17-
POSTGRES_USER: postgres
18-
POSTGRES_PASSWORD: postgres
19-
POSTGRES_DB: postgres
20-
ports:
21-
- 5432:5432
22-
# needed because the postgres container does not provide a healthcheck
23-
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
24-
2513
steps:
2614
- uses: actions/checkout@v4
27-
- uses: actions/setup-python@v4
15+
- uses: actions/setup-go@v4
2816
with:
29-
python-version: 3.9
30-
- name: Install python dependencies
31-
working-directory: ./examples/python
32-
run: |
33-
python -m pip install --upgrade pip
34-
python -m pip install -r requirements.txt
35-
- name: Test python code
36-
working-directory: ./examples/python
37-
env:
38-
PG_USER: postgres
39-
PG_HOST: localhost
40-
PG_DATABASE: postgres
41-
PG_PASSWORD: postgres
42-
PG_PORT: ${{ job.services.postgres.ports['5432'] }}
43-
run: |
44-
pytest src/tests
17+
go-version: '1.21.3'
18+
- name: install ./...
19+
run: go install ./...
20+
- uses: actions/checkout@v4
21+
repository: sqlc-dev/sqlc-gen-python
22+
path: python
23+
- run: make test
24+
working-directory: python

0 commit comments

Comments
 (0)