Skip to content

Commit 64aaa92

Browse files
committed
Add github action to run tests
1 parent 10e40cb commit 64aaa92

File tree

4 files changed

+56
-11
lines changed

4 files changed

+56
-11
lines changed

.coveragerc

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

.github/workflows/test.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Test
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
8+
jobs:
9+
test:
10+
runs-on: ${{ matrix.os }}
11+
strategy:
12+
fail-fast: false
13+
matrix:
14+
os: ["ubuntu-latest"]
15+
python-version: [3.5, 3.6, 3.7, 3.8, 3.9, "pypy-3.6", "pypy-3.7"]
16+
steps:
17+
- name: Checkout
18+
uses: actions/checkout@v2
19+
- name: Set up Python
20+
uses: actions/setup-python@v2
21+
with:
22+
python-version: ${{ matrix.python-version }}
23+
- name: Install dependencies
24+
run: |
25+
python -m pip install --upgrade pip setuptools wheel
26+
pip install coverage pep8 pytest
27+
pip install -e .
28+
- name: PyTest
29+
run: |
30+
coverage run -m pytest --doctest-modules toolz/
31+
pytest bench/
32+
pep8 --ignore="E731,W503,E402" --exclude=conf.py,tests,examples,bench -r --show-source .
33+
34+
finish:
35+
needs: test
36+
runs-on: ubuntu-latest
37+
steps:
38+
- name: Coveralls Finished
39+
uses: coverallsapp/github-action@master
40+
with:
41+
github-token: ${{ secrets.github_token }}
42+
parallel-finished: true

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@ dist/
44
*.egg-info/
55
bench/shakespeare.txt
66
.coverage
7-
7+
*.sw?
8+
.DS_STORE
89
\.tox/

setup.cfg

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,15 @@ versionfile_source = toolz/_version.py
55
versionfile_build = toolz/_version.py
66
tag_prefix =
77
parentdir_prefix = toolz-
8+
9+
[coverage:run]
10+
source = toolz
11+
omit =
12+
toolz/tests/test*
13+
toolz/*/tests/test*
14+
toolz/compatibility.py
15+
toolz/_version.py
16+
17+
[coverage:report]
18+
exclude_lines =
19+
pragma: no cover

0 commit comments

Comments
 (0)