summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorMichael Howitz <mh@gocept.com>2020-11-17 08:11:40 +0100
committerGitHub <noreply@github.com>2020-11-17 08:11:40 +0100
commit56581e9fde82e26db952a9eee0317891933b74d1 (patch)
treee77bade4b60d8035779e5a053b8a10cca7c5dd4c /.github
parent815752c15d8beb6d0a33b20845cbcce86f4cb3f8 (diff)
downloadzope-browser-56581e9fde82e26db952a9eee0317891933b74d1.tar.gz
Activate GH actions. (#7)
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/tests.yml42
1 files changed, 22 insertions, 20 deletions
diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
index e188bf0..bed4805 100644
--- a/.github/workflows/tests.yml
+++ b/.github/workflows/tests.yml
@@ -2,48 +2,50 @@ name: run tests
on:
push:
+ pull_request:
schedule:
- - cron: '* * * * 0' # run once a week (sunday)
+ - cron: '0 12 * * 0' # run once a week on Sunday
jobs:
build:
strategy:
matrix:
- python-version:
- - "2.7"
- - "3.5"
- - "3.6"
- - "3.7"
- - "3.8"
- - "3.9"
- - "pypy2"
- - "pypy3"
- include:
- - python-version: "3.8"
- env:
- - lint
- - coverage
+ config:
+ # [name, Python version, tox env]
+ - ["lint", "3.8", "lint"]
+ - ["2.7", "2.7", "py27"]
+ - ["3.5", "3.5", "py35"]
+ - ["3.6", "3.6", "py36"]
+ - ["3.7", "3.7", "py37"]
+ - ["3.8", "3.8", "py38"]
+ - ["3.9", "3.9", "py39"]
+ - ["pypy2", "pypy2", "pypy"]
+ - ["pypy3", "pypy3", "pypy3"]
+ - ["coverage", "3.8", "coverage"]
runs-on: ubuntu-latest
+ name: ${{ matrix.config[0] }}
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
- python-version: ${{ matrix.python-version }}
+ python-version: ${{ matrix.config[1] }}
- name: Pip cache
uses: actions/cache@v2
with:
path: ~/.cache/pip
- key: ${{ runner.os }}-pip-${{ hashFiles(setup.*', 'tox.ini') }}
+ key: ${{ runner.os }}-pip-${{ hashFiles('setup.*', 'tox.ini') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Install dependencies
run: |
python -m pip install --upgrade pip
- pip install coveralls
+ pip install tox coveralls
- name: Test
- run: tox -e {{ matrix.env || 'py'}}
+ run: tox -e ${{ matrix.config[2] }}
- name: Coverage
+ if: matrix.config[1] == 'coverage'
run: coveralls
- if: {{ matrix.env == 'coverage'}}
+ env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}