diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index a535e16..38cb0de 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -4,14 +4,17 @@ name: tests on: push: - branches: [ master ] pull_request: schedule: - cron: '0 12 * * 0' # run once a week on Sunday + # Allow to run this workflow manually from the Actions tab + workflow_dispatch: jobs: build: strategy: + # We want to see all failures: + fail-fast: false matrix: config: # [Python version, tox env] @@ -32,7 +35,7 @@ jobs: steps: - uses: actions/checkout@v2 - name: Set up Python - uses: actions/setup-python@v2.1.4 + uses: actions/setup-python@v2 with: python-version: ${{ matrix.config[0] }} - name: Pip cache diff --git a/.gitignore b/.gitignore index 0aadbae..9a9e9b9 100644 --- a/.gitignore +++ b/.gitignore @@ -10,16 +10,20 @@ .installed.cfg .mr.developer.cfg .tox/ +.vscode/ __pycache__/ bin/ build/ coverage.xml develop-eggs/ +develop/ dist/ docs/_build eggs/ -htmlcov/ +etc/ lib/ lib64 +log/ parts/ pyvenv.cfg +var/ diff --git a/.meta.toml b/.meta.toml index e6be31a..0c6365a 100644 --- a/.meta.toml +++ b/.meta.toml @@ -2,7 +2,7 @@ # https://github.com/zopefoundation/meta/tree/master/config/pure-python [meta] template = "pure-python" -commit-id = "4e9825189b9b8d18f28e7dbc63373d4baea08602" +commit-id = "b3b903c81546d54b062adf7fafa32e06125f5ba1" [python] with-pypy = true @@ -13,3 +13,11 @@ with-appveyor = false [coverage] fail-under = 100 + +[tox] +use-flake8 = true + +[manifest] +additional-rules = [ + "recursive-include src *.rst", + ] diff --git a/MANIFEST.in b/MANIFEST.in index 0676639..b184ee1 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -5,14 +5,10 @@ include *.txt include buildout.cfg include tox.ini -recursive-include docs *.bat recursive-include docs *.py recursive-include docs *.rst recursive-include docs *.txt recursive-include docs Makefile -recursive-include src *.pt recursive-include src *.py recursive-include src *.rst -recursive-include src *.txt -recursive-include src *.zcml diff --git a/tox.ini b/tox.ini index 7d9fc1e..bd91068 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,7 @@ # Generated from: # https://github.com/zopefoundation/meta/tree/master/config/pure-python [tox] +minversion = 3.18 envlist = lint py27 @@ -19,7 +20,7 @@ usedevelop = true deps = zope.testrunner commands = - zope-testrunner --test-path=src [] + zope-testrunner --test-path=src {posargs:-vc} extras = test @@ -37,19 +38,26 @@ commands = [testenv:docs] basepython = python3 +skip_install = false +# Until repoze.sphinx.autointerface supports Sphinx 4.x we cannot use it: +deps = Sphinx < 4 extras = docs +commands_pre = commands = sphinx-build -b html -d docs/_build/doctrees docs docs/_build/html [testenv:coverage] basepython = python3 +allowlist_externals = + mkdir deps = coverage coverage-python-version zope.testrunner commands = - coverage run -m zope.testrunner --test-path=src [] + mkdir -p {toxinidir}/parts/htmlcov + coverage run -m zope.testrunner --test-path=src {posargs:-vc} coverage html coverage report -m --fail-under=100 @@ -70,4 +78,4 @@ exclude_lines = raise AssertionError [coverage:html] -directory = htmlcov +directory = parts/htmlcov