From b44efa7eb6057efe4a1be8718bc564f04b2017c5 Mon Sep 17 00:00:00 2001 From: Andreas Motl Date: Sun, 9 Apr 2023 23:24:46 +0200 Subject: [PATCH] CI: Add GHA configuration to invoke software tests --- .github/dependabot.yml | 11 ++++++++ .github/workflows/tests.yml | 56 +++++++++++++++++++++++++++++++++++++ CHANGES.rst | 1 + 3 files changed, 68 insertions(+) create mode 100644 .github/dependabot.yml create mode 100644 .github/workflows/tests.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..3bf1101 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,11 @@ +# To get started with Dependabot version updates, you'll need to specify which +# package ecosystems to update and where the package manifests are located. +# Please see the documentation for all configuration options: +# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates + +version: 2 +updates: + - package-ecosystem: "pip" # See documentation for possible values + directory: "/" # Location of package manifests + schedule: + interval: "monthly" diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml new file mode 100644 index 0000000..55bde67 --- /dev/null +++ b/.github/workflows/tests.yml @@ -0,0 +1,56 @@ +name: Tests + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + + # Allow job to be triggered manually. + workflow_dispatch: + +# Cancel in-progress jobs when pushing to the same branch. +concurrency: + cancel-in-progress: true + group: ${{ github.workflow }}-${{ github.ref }} + +jobs: + + tests: + runs-on: ${{ matrix.os }} + + strategy: + fail-fast: false + matrix: + os: [ "ubuntu-20.04" ] + python-version: [ "3.6", "3.7", "3.8", "3.9", "3.10", "3.11" ] + + name: Python ${{ matrix.python-version }} on OS ${{ matrix.os }} + steps: + + - name: Acquire sources + uses: actions/checkout@v3 + + - name: Setup Python + uses: actions/setup-python@v4 + with: + python-version: ${{ matrix.python-version }} + architecture: x64 + cache: 'pip' + cache-dependency-path: | + requirements-docs.txt + requirements-release.txt + requirements-test.txt + setup.py + + - name: Run tests + run: make test + + - name: Upload coverage to Codecov + uses: codecov/codecov-action@v3 + with: + files: ./coverage.xml + flags: unittests + env_vars: OS,PYTHON + name: codecov-umbrella + fail_ci_if_error: false diff --git a/CHANGES.rst b/CHANGES.rst index 5a30f9e..abfebc0 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -9,6 +9,7 @@ development - Fix SQL filtering with DuckDB - Tests: Add software tests - Improve documentation +- CI: Add GHA configuration to invoke software tests 2020-12-29 0.11.0 =================