Release v11.3.0
#238
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: test | |
on: | |
push: | |
branches: | |
- master | |
- dev | |
pull_request: | |
branches: | |
- master | |
workflow_dispatch: | |
jobs: | |
test: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- ubuntu-20.04 | |
- macos-13 | |
- macos-14 | |
- windows-2019 | |
node: | |
- 18 | |
- 20 | |
- 22 | |
name: Testing Node ${{ matrix.node }} on ${{ matrix.os }} | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ matrix.node }} | |
- if: ${{ startsWith(matrix.os, 'windows') }} | |
run: pip.exe install setuptools | |
- if: ${{ startsWith(matrix.os, 'macos') }} | |
run: brew install python-setuptools | |
- if: ${{ !startsWith(matrix.os, 'windows') && !startsWith(matrix.os, 'macos') }} | |
run: python3 -m pip install setuptools | |
- if: ${{ startsWith(matrix.os, 'ubuntu') }} | |
run: | | |
sudo apt update | |
sudo apt install gcc-10 g++-10 -y | |
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-10 100 --slave /usr/bin/g++ g++ /usr/bin/g++-10 --slave /usr/bin/gcov gcov /usr/bin/gcov-10 | |
- run: npm install --ignore-scripts | |
- run: npm run build-debug | |
- run: npm test | |
- name: Test SpatiaLite extension | |
if: ${{ startsWith(matrix.os, 'ubuntu') }} | |
run: | | |
sudo apt update | |
sudo apt install libsqlite3-mod-spatialite -y | |
node -e "require('./lib/index.js')(':memory:').loadExtension('mod_spatialite').exec('SELECT InitSpatialMetaData();')" | |
test-alpine-linux: | |
name: Testing Node 20 on Alpine-Linux | |
runs-on: ubuntu-latest | |
container: node:20-alpine | |
steps: | |
- uses: actions/checkout@v4 | |
- run: apk add build-base git python3 py3-setuptools --update-cache | |
- run: npm install --ignore-scripts | |
- run: npm run build-debug | |
- run: npm test | |
test-alpine-linux-arm64: | |
name: Testing Node 20 on Alpine-Linux (arm64) | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: docker/setup-qemu-action@v3 | |
- run: | | |
docker run --rm -v $(pwd):/tmp/project --entrypoint /bin/sh --platform linux/arm64 node:20-alpine -c "\ | |
apk add build-base git python3 py3-setuptools --update-cache && \ | |
cd /tmp/project && \ | |
npm install --ignore-scripts && \ | |
npm run build-debug && \ | |
npm test" | |
test-linux-arm: | |
strategy: | |
fail-fast: false | |
matrix: | |
arch: | |
- arm/v7 | |
- arm64 | |
name: Testing Node 20 on Linux (${{ matrix.arch }}) | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: docker/setup-qemu-action@v3 | |
- run: | | |
docker run --rm -v $(pwd):/tmp/project --entrypoint /bin/sh --platform linux/${{ matrix.arch }} node:20 -c "\ | |
cd /tmp/project && \ | |
npm install --ignore-scripts && \ | |
npm run build-debug && \ | |
npm test" |