Skip to content

Commit 486d4af

Browse files
committed
CI: move testing into virtualenv
1 parent bf10625 commit 486d4af

File tree

3 files changed

+17
-20
lines changed

3 files changed

+17
-20
lines changed

.github/actions/run-tests/action.yml

Lines changed: 0 additions & 12 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -109,15 +109,19 @@ jobs:
109109

110110
- name: Install osmium
111111
run: |
112-
pip install osmium*${PYVER/./}*.whl
112+
pip install virtualenv
113+
virtualenv osmium-test
114+
WHEEL=`ls osmium*${PYVER/./}*.whl`
115+
./osmium-test/bin/pip install ${WHEEL}[tests]
113116
shell: bash
114117
env:
115118
PYVER: ${{ matrix.python-version }}
116119

117-
- uses: ./.github/actions/run-tests
118-
120+
- name: Run tests
121+
run: ./osmium-test/bin/pytest test
122+
shell: bash
119123

120-
build-ubuntu:
124+
build-platform:
121125
runs-on: ${{ matrix.platform }}
122126

123127
strategy:
@@ -193,7 +197,7 @@ jobs:
193197
if: ${{ matrix.flavour == 'linux' }}
194198

195199
- name: Install packages
196-
run: brew install boost geos lz4
200+
run: brew install boost geos
197201
shell: bash
198202
if: ${{ matrix.flavour == 'macos' }}
199203

@@ -345,9 +349,14 @@ jobs:
345349

346350
- name: Install osmium
347351
run: |
348-
pip install osmium*${PYVER/./}*.whl
352+
pip install virtualenv
353+
virtualenv osmium-test
354+
WHEEL=`ls osmium*${PYVER/./}*.whl`
355+
./osmium-test/Scripts/pip install ${WHEEL}[tests]
349356
shell: bash
350357
env:
351358
PYVER: ${{ matrix.python-version }}
352359

353-
- uses: ./.github/actions/run-tests
360+
- name: Run tests
361+
run: ./osmium-test/Scripts/pytest test
362+
shell: bash

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ def build_extension(self, ext):
177177
python_requires = ">=3.7",
178178
install_requires = ['requests'],
179179
extras_require = {
180-
'tests': ['pytest', 'pytest-httpserver', 'werkzeug'],
180+
'tests': ['pytest', 'pytest-httpserver', 'werkzeug', 'shapely'],
181181
},
182182
cmdclass=dict(build_ext=CMakeBuild, sdist=Pyosmium_sdist),
183183
zip_safe=False,

0 commit comments

Comments
 (0)