Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setup GHA. #7

Merged
merged 3 commits into from
Nov 20, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 56 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Generated from:
# https://github.com/zopefoundation/meta/tree/master/config/pure-python
name: tests

on:
push:
branches: [ master ]
pull_request:
schedule:
- cron: '0 12 * * 0' # run once a week on Sunday

jobs:
build:
strategy:
matrix:
config:
# [Python version, tox env]
- ["3.8", "lint"]
- ["2.7", "py27"]
- ["3.5", "py35"]
- ["3.6", "py36"]
- ["3.7", "py37"]
- ["3.8", "py38"]
- ["3.9", "py39"]
- ["pypy2", "pypy"]
- ["pypy3", "pypy3"]
- ["3.8", "coverage"]

runs-on: ubuntu-latest
name: ${{ matrix.config[1] }}
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.config[0] }}
- name: Pip cache
uses: actions/cache@v2
with:
path: ~/.cache/pip
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 tox
- name: Test
run: tox -e ${{ matrix.config[1] }}
- name: Coverage
if: matrix.config[1] == 'coverage'
run: |
pip install coveralls coverage-python-version
coveralls
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3 changes: 2 additions & 1 deletion .meta.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# https://github.com/zopefoundation/meta/tree/master/config/pure-python
[meta]
template = pure-python
commit-id = ee6aa5dbb1a7c31c7655fb0cefe0091b9fccf6c8
commit-id = 1f1620d8f96c3f3781d1df0c591dd72a3f068879
fail-under = 0
with-pypy = True

34 changes: 0 additions & 34 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion CHANGES.txt → CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Changelog
4.2.1 (unreleased)
------------------

- Nothing changed yet.
- Add support for Python 3.9.


4.2.0 (2020-05-20)
Expand Down
4 changes: 2 additions & 2 deletions MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ include *.rst
include *.txt
include buildout.cfg
include tox.ini

exclude MANIFEST.in
include .coveragerc

recursive-include docs *.bat
recursive-include docs *.py
recursive-include docs *.rst
recursive-include docs *.txt
recursive-include docs Makefile

recursive-include src *.gif
Expand Down
File renamed without changes.
1 change: 0 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,3 @@ doctests = 1
ignore =
.editorconfig
.meta.cfg
.travis.yml
11 changes: 6 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,17 +34,17 @@ def read(*rnames):
author_email='zope-dev@zope.org',
description="Zope app setup helper",
long_description=(
read('README.txt') +
read('README.rst') +
'\n\n' +
'.. contents::' +
'\n\n' +
read('src', 'zope', 'app', 'appsetup', 'bootstrap.txt') +
read('src', 'zope', 'app', 'appsetup', 'bootstrap.rst') +
'\n\n' +
read('src', 'zope', 'app', 'appsetup', 'debug.txt') +
read('src', 'zope', 'app', 'appsetup', 'debug.rst') +
'\n\n' +
read('src', 'zope', 'app', 'appsetup', 'product.txt') +
read('src', 'zope', 'app', 'appsetup', 'product.rst') +
'\n\n' +
read('CHANGES.txt')
read('CHANGES.rst')
),
license='ZPL 2.1',
keywords="zope3 app setup",
Expand All @@ -60,6 +60,7 @@ def read(*rnames):
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: Implementation',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy',
Expand Down
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions src/zope/app/appsetup/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -278,18 +278,18 @@ def test_suite():
test = doctest.DocTestSuite('zope.app.appsetup.appsetup')
test.layer = layer
suite.addTest(test)
for filename in ['bootstrap.txt', 'product.txt']:
for filename in ['bootstrap.rst', 'product.rst']:
test = doctest.DocFileSuite(filename,
optionflags=dtflags,
checker=checker)
test.layer = layer
suite.addTest(test)

test = doctest.DocFileSuite('debug.txt')
test = doctest.DocFileSuite('debug.rst')
test.layer = DebugLayer(zope.app.appsetup)
suite.addTest(test)
suite.addTest(doctest.DocFileSuite(
'testlayer.txt',
'testlayer.rst',
optionflags=dtflags))

return suite
4 changes: 3 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,12 @@
envlist =
lint,
py27,
pypy,
py35,
py36,
py37,
py38,
py39,
pypy,
pypy3,
coverage

Expand Down Expand Up @@ -51,6 +52,7 @@ source = src
[coverage:report]
precision = 2
exclude_lines =
pragma: no cover
pragma: nocover
except ImportError:
raise NotImplementedError
Expand Down