-
Notifications
You must be signed in to change notification settings - Fork 3
57 lines (48 loc) · 1.49 KB
/
unit-tests-noconda.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
name: Unit Tests - No Conda
on:
push:
branches:
- 'release'
- 'development'
- 'main'
pull_request:
branches:
- '*'
jobs:
Test-Package:
runs-on: ${{ matrix.os }}
strategy:
max-parallel: 4
fail-fast: true
matrix:
os: [ubuntu-latest]
python-version: ["3.8", "3.9", "3.10", "3.11",]
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Set Up Python Ubuntu
uses: actions/setup-python@v4
if: matrix.os == 'ubuntu-latest'
with:
python-version: ${{ matrix.python-version }}
- name: Apt Package Cache Update
if: matrix.os == 'ubuntu-latest'
run: sudo apt-get update
- name: Install GDAL Ubuntu
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get install gdal-bin libgdal-dev
echo "CPLUS_INCLUDE_PATH=/usr/include/gdal" >> $GITHUB_ENV
echo "C_INCLUDE_PATH=/usr/include/gdal" >> $GITHUB_ENV
ogrversion=`ogrinfo --version | grep -oP "\d+\.\d+\.\d+"`
echo "OGRVERSION=$ogrversion" >> $GITHUB_ENV
- name: Install Dependencies Ubuntu
if: matrix.os == 'ubuntu-latest'
run: |
python -m pip install --upgrade pip
python -m pip install 'gdal==${{ env.OGRVERSION }}'
python -m pip install -r requirements.txt
- name: Test with Pytest
if: matrix.os == 'ubuntu-latest'
shell: bash -el {0}
run: pytest