Skip to content

build

build #129

Workflow file for this run

# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
name: build
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
# 3 am Tuesdays and Fridays
- cron: "0 3 * * 2,5"
concurrency:
group: "${{ github.ref }}-${{ github.head_ref }}-${{ github.workflow }}"
cancel-in-progress: true
jobs:
build:
defaults:
run:
shell: bash -l {0}
runs-on: ${{matrix.os}}
strategy:
max-parallel: 12
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ['3.8', '3.9', '3.10', '3.11']
steps:
- uses: actions/checkout@v3
- name: Setup Miniconda
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
use-mamba: true
python-version: ${{ matrix.python-version }}
environment-file: environment.yaml
activate-environment: pytng
- name: Install Pytng
run: |
python -m pip install .
- name: Test with pytest
run: |
pytest -v -ra ./tests/
pip-install:
# A pure Python install, which relies purely on pyproject.toml contents
defaults:
run:
shell: bash {0}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python: ["3.8", "3.9", "3.10", "3.11"]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: check_env
run: |
which python
python -m pip list
- name: build
run: python -m pip -v install .
- name: install_reqs
run: pip install pytest
- name: pytests
run: |
pytest -v -ra ./tests/