Skip to content

Commit e8c3c99

Browse files
committed
Add GitHub Actions checks, remove TravisCI
1 parent 08c0c4d commit e8c3c99

File tree

3 files changed

+41
-13
lines changed

3 files changed

+41
-13
lines changed

.github/workflows/checks.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: tests
2+
3+
on:
4+
push:
5+
branches: [ develop ]
6+
pull_request:
7+
branches: [ develop ]
8+
9+
jobs:
10+
build:
11+
12+
runs-on: ubuntu-latest
13+
strategy:
14+
matrix:
15+
python-version: [3.6, 3.7, 3.8, 3.9]
16+
17+
steps:
18+
- uses: actions/checkout@v2
19+
- name: Set up Python ${{ matrix.python-version }}
20+
uses: actions/setup-python@v1
21+
with:
22+
python-version: ${{ matrix.python-version }}
23+
- name: Install dependencies
24+
run: |
25+
python -m pip install --upgrade pip
26+
pip install .[tests]
27+
- name: Lint with flake8
28+
run: |
29+
# stop the build if there are Python syntax errors or undefined names
30+
flake8 delphin --count --select=E9,F63,F7,F82 --show-source --statistics
31+
# exit-zero treats all errors as warnings. PEP-8 says 99 chars is a good width
32+
flake8 delphin --count --exit-zero --extend-ignore E221 --max-line-length=99 --statistics
33+
# E221 = whitespace before operator
34+
# disabled for now: --max-complexity=10
35+
- name: Test with pytest
36+
run: |
37+
pytest .
38+
- name: Type-check with mypy
39+
run: |
40+
mypy delphin --namespace-packages --explicit-package-bases --ignore-missing-imports

.travis.yml

Lines changed: 0 additions & 12 deletions
This file was deleted.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[![PyPI Version](https://img.shields.io/pypi/v/pydelphin.svg)](https://pypi.org/project/PyDelphin/)
44
![Python Support](https://img.shields.io/pypi/pyversions/pydelphin.svg)
5-
[![Build Status](https://travis-ci.org/delph-in/pydelphin.svg)](https://travis-ci.org/delph-in/pydelphin)
5+
[![Test Status](https://github.com/delph-in/pydelphin/workflows/tests/badge.svg)](https://github.com/delph-in/pydelphin/actions?query=workflow%3A%22tests%22)
66
[![Documentation Status](https://readthedocs.org/projects/pydelphin/badge/?version=latest)](https://pydelphin.readthedocs.io/en/latest/?badge=latest)
77

88
[DELPH-IN](http://delph-in.net) is an international consortium of

0 commit comments

Comments
 (0)