-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (53 loc) · 1.27 KB
/
run-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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: Run tests
on:
pull_request:
push:
branches:
- main
- develop
# Probably should add a release process to publish a package we install
# one day...
# release:
# types:
# - created
jobs:
linting:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Check linting
uses: psf/black@stable
id: action_black
with:
options: "--check"
src: "./dep_tools"
testing:
runs-on: ubuntu-latest
container:
image: ghcr.io/osgeo/gdal:ubuntu-full-3.8.4
volumes:
- ${{ github.workspace }}:/github/workspace
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install dependencies and run tests
run: |
apt-get update && apt-get install -y \
python3-pip \
python3-dev \
git \
libpq-dev \
ca-certificates \
build-essential
pip3 install --upgrade pip setuptools wheel poetry
pip3 install .
- name: Run tests
run: |
pip3 install pytest
cd /github/workspace
pytest tests