Skip to content

Open source NengoSPA #21

Open source NengoSPA

Open source NengoSPA #21

Workflow file for this run

name: CI testing
on:
pull_request: {}
push:
branches:
- main
- release-candidate-*
tags:
- v*
workflow_dispatch:
inputs:
debug_enabled:
description: Run the build with SSH debugging enabled
type: boolean
required: false
default: false
defaults:
run:
shell: bash -el {0}
jobs:
test:
runs-on: ubuntu-latest
timeout-minutes: 60
strategy:
matrix:
include:
- script: static
- script: docs
- script: test
numpy-version: numpy==1.21.0
scipy-version: scipy==1.4.1
python-version: "3.8"
- script: test
python-version: "3.9"
- script: test-coverage
coverage-name: with-scipy
- script: test-coverage-no-scipy
coverage-name: no-scipy
fail-fast: false
env:
NUMPY: ${{ matrix.numpy-version || 'numpy' }}
SCIPY: ${{ matrix.scipy-version || 'scipy' }}
GH_TOKEN: ${{ secrets.PUBLIC_GH_TOKEN }}
steps:
- uses: nengo/nengo-bones/actions/setup@main
with:
python-version: ${{ matrix.python-version || '3.8' }}
- name: Install pandoc
if: ${{ matrix.script == 'docs' }}
run: |
micromamba install pandoc
- uses: nengo/nengo-bones/actions/generate-and-check@main
- uses: nengo/nengo-bones/actions/run-script@main
with:
name: ${{ matrix.script }}
- uses: actions/upload-artifact@v3
if: ${{ always() && matrix.coverage-name }}
with:
name: coverage-${{ matrix.coverage-name }}
path: .coverage
coverage:
runs-on: ubuntu-latest
timeout-minutes: 10
needs:
- test
if: ${{ always() }}
steps:
- uses: nengo/nengo-bones/actions/coverage-report@main
with:
min-coverage: 95
deploy:
needs:
- test
if: >-
startsWith(github.ref_name, 'release-candidate-') ||
(github.ref_type == 'tag' && startsWith(github.ref_name, 'v'))
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- name: Write .pypirc to file
run: |
echo '${{ secrets.PYPIRC_FILE }}' > ~/.pypirc
- uses: actions/checkout@v3
- uses: nengo/nengo-bones/actions/setup@main
- uses: nengo/nengo-bones/actions/generate-and-check@main
- uses: nengo/nengo-bones/actions/run-script@main
with:
name: deploy