Skip to content

Commit

Permalink
Merge pull request #488 from hameerabbasi/gh-actions
Browse files Browse the repository at this point in the history
Add GitHub actions.
  • Loading branch information
hameerabbasi authored Jun 13, 2021
2 parents 15f36a6 + 403f348 commit f2c74d8
Showing 1 changed file with 49 additions and 0 deletions.
49 changes: 49 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
jobs:
test:
strategy:
matrix:
platform:
- os: ubuntu-latest
miniconda-url: https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh
- os: macos-latest
miniconda-url: https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-MacOSX-x86_64.sh
- os: windows-latest
miniconda-url: https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Windows-x86_64.exe
python: [3.7, 3.8, 3.9]
runs-on: ${{ matrix.os }}
env:
PYTHON_VERSION: ${{ matrix.python }}

steps:
- name: Checkout Repo
uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
installer-url: ${{ matrix.miniconda-url }}
activate-environment: sparse-dev
allow-softlinks: true
- name: Install package
run: |
conda create -n sparse-dev python=$PYTHON_VERSION
pip install -e .[tests]
pip install codecov
- name: Run tests
run: |
pytest --pyargs sparse
- uses: codecov/codecov-action@v1
on:
# Trigger the workflow on push or pull request,
# but only for the main branch
push:
branches:
- main
- vnext
pull_request:
branches:
- main
- vnext
# Also trigger on page_build, as well as release created events
page_build:
release:
types: # This configuration does not affect the page_build event above
- created

0 comments on commit f2c74d8

Please sign in to comment.