Skip to content

.github/workflows/unittests.yml #1260

.github/workflows/unittests.yml

.github/workflows/unittests.yml #1260

Workflow file for this run

on:
push:
branches:
- '*'
pull_request:
branches:
- '*'
schedule:
- cron: '59 23 * * *'
workflow_dispatch:
inputs:
version:
description: Manual Unittest Run
default: test
required: false
jobs:
unittests:
name: conda (${{ matrix.os }}, ${{ matrix.environment-file }})
runs-on: ${{ matrix.os }}
timeout-minutes: 45
env:
RUN_TEST: pytest tigernet --cov tigernet -v -n auto --doctest-modules --cov-config .coveragerc --cov-report xml --color yes --cov-append --cov-report term-missing
strategy:
matrix:
environment-file: [.ci/38.yaml, .ci/39.yaml, .ci/310.yaml]
os: ['ubuntu-latest']
include:
- environment-file: .ci/310.yaml
os: macos-latest
- environment-file: .ci/310.yaml
os: windows-latest
steps:
- name: checkout repo
uses: actions/checkout@v4
- name: setup micromamba
uses: mamba-org/provision-with-micromamba@main
with:
environment-file: ${{ matrix.environment-file }}
micromamba-version: 'latest'
- name: run tests - bash
shell: bash -l {0}
run: ${{ env.RUN_TEST }}
if: matrix.os != 'windows-latest'
- name: run tests - powershell
shell: powershell
run: ${{ env.RUN_TEST }}
if: matrix.os == 'windows-latest'
- name: codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
name: tigernet-codecov