Skip to content

Commit

Permalink
Replaced travis CI with github workflows for automated testing.
Browse files Browse the repository at this point in the history
  • Loading branch information
pcubillos committed Mar 27, 2024
1 parent 91a537f commit a52a31a
Show file tree
Hide file tree
Showing 3 changed files with 56 additions and 16 deletions.
52 changes: 52 additions & 0 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python

name: Tests

on:
push:
branches: [ "*" ]
pull_request:
branches: [ "master" ]
schedule:
- cron: '0 12 1 * *'

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]
os: [ubuntu-latest]

steps:

- name: check out
uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install flake8 pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Install package
run: |
python -m pip install -e .
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
run: |
pytest tests -v
16 changes: 0 additions & 16 deletions .travis.yml

This file was deleted.

4 changes: 4 additions & 0 deletions CHANGELOG.txt
Original file line number Diff line number Diff line change
Expand Up @@ -754,3 +754,7 @@ Updated the pup marker to work with matplotlib v3.4+

Getting the docs back to life.

*****

Replaced travis CI with github workflows for automated testing.

0 comments on commit a52a31a

Please sign in to comment.