Skip to content

Commit

Permalink
Merge pull request #7 from zopefoundation/issue6
Browse files Browse the repository at this point in the history
Add Python 3.6 and coveralls
  • Loading branch information
jamadden committed Jun 26, 2017
2 parents f1d3775 + 1106cd0 commit c8110ad
Show file tree
Hide file tree
Showing 11 changed files with 103 additions and 54 deletions.
8 changes: 8 additions & 0 deletions .coveragerc
@@ -0,0 +1,8 @@
[run]
source = zope.event

[report]
exclude_lines =
pragma: no cover
if __name__ == '__main__':
raise NotImplementedError
2 changes: 2 additions & 0 deletions .gitignore
Expand Up @@ -11,6 +11,8 @@ __pycache__
build
docs/_build
.coverage
.coverage.*
htmlcov
nosetests.xml
coverage.xml
.installed.cfg
Expand Down
32 changes: 22 additions & 10 deletions .travis.yml
@@ -1,15 +1,27 @@
language: python
sudo: false
python:
- 2.7
- 3.3
- 3.4
- 3.5
- pypy
- pypy3
install:
- pip install .
- 2.7
- 3.4
- 3.5
- 3.6
- pypy-5.6.0
- pypy3.3-5.5-alpha
script:
- python setup.py -q test -q
- coverage run -m zope.testrunner --test-path=src

after_success:
- coveralls
notifications:
email: false
email: false

install:
- pip install -U pip setuptools
- pip install -U coveralls coverage
- pip install -U -e ".[test]"


cache: pip

before_cache:
- rm -f $HOME/.cache/pip/log/debug.log
35 changes: 19 additions & 16 deletions CHANGES.rst
@@ -1,52 +1,55 @@
``zope.event`` Changelog
========================
==========================
``zope.event`` Changelog
==========================

4.2.1 (unreleased)
------------------
4.3.0 (unreleased)
==================

- TBD
- Add support for Python 3.6.

- Drop support for Python 3.3.


4.2.0 (2016-02-17)
------------------
==================

- Add support for Python 3.5.

- Drop support for Python 2.6 and 3.2.


4.1.0 (2015-10-18)
------------------
==================

- Require 100% branch (as well as statement) coverage.

- Add a simple class-based handler implementation.


4.0.3 (2014-03-19)
------------------
==================

- Add support for Python 3.4.

- Update ``boostrap.py`` to version 2.2.


4.0.2 (2012-12-31)
------------------
==================

- Flesh out PyPI Trove classifiers.

- Add support for jython 2.7.


4.0.1 (2012-11-21)
------------------
==================

- Add support for Python 3.3.


4.0.0 (2012-05-16)
------------------
==================

- Automate build of Sphinx HTML docs and running doctest snippets via tox.

Expand All @@ -56,7 +59,7 @@


3.5.2 (2012-03-30)
------------------
==================

- This release is the last which will maintain support for Python 2.4 /
Python 2.5.
Expand All @@ -70,26 +73,26 @@


3.5.1 (2011-08-04)
------------------
==================

- Add Sphinx documentation.


3.5.0 (2010-05-01)
------------------
==================

- Add change log to ``long-description``.

- Add support for Python 3.x.


3.4.1 (2009-03-03)
------------------
==================

- A few minor cleanups.


3.4.0 (2007-07-14)
------------------
==================

- Initial release as a separate project.
11 changes: 10 additions & 1 deletion MANIFEST.in
@@ -1,11 +1,20 @@
include *.rst
include *.txt

recursive-include docs *
include .travis.yml
include .coveragerc
include tox.ini
include bootstrap.py
include buildout.cfg

recursive-include docs *.rst *.py Makefile make.bat
recursive-include docs/_static *
recursive-include src *

global-exclude *.dll
global-exclude *.pyc
global-exclude *.pyo
global-exclude *.so
global-exclude *.class

recursive-exclude docs/_build *
7 changes: 4 additions & 3 deletions README.rst
@@ -1,5 +1,6 @@
``zope.event`` README
=====================
=======================
``zope.event`` README
=======================

.. image:: https://img.shields.io/pypi/v/zope.event.svg
:target: https://pypi.python.org/pypi/zope.event/
Expand All @@ -22,4 +23,4 @@ The ``zope.event`` package provides a simple event system, including:
event dispatching system that builds on ``zope.event`` can be found in
``zope.component``.

Please see http://zopeevent.rtfd.org/ for the documentation.
Please see http://zopeevent.readthedocs.io/ for the documentation.
2 changes: 2 additions & 0 deletions setup.cfg
Expand Up @@ -11,3 +11,5 @@ where=src
dev = develop easy_install zope.event[testing]
docs = easy_install zope.event[docs]

[bdist_wheel]
universal = 1
24 changes: 15 additions & 9 deletions setup.py
Expand Up @@ -23,12 +23,13 @@
from setuptools import setup, find_packages

def read(*rnames):
return open(os.path.join(os.path.dirname(__file__), *rnames)).read()
with open(os.path.join(os.path.dirname(__file__), *rnames)) as f:
return f.read()

setup(
name='zope.event',
version='4.2.1.dev0',
url='http://pypi.python.org/pypi/zope.event',
url='http://github.com/zopefoundation/zope.event',
license='ZPL 2.1',
description='Very basic event publishing system',
author='Zope Foundation and Contributors',
Expand All @@ -37,7 +38,8 @@ def read(*rnames):
read('README.rst')
+ '\n' +
read('CHANGES.rst')
),
),
keywords="event framework dispatch subscribe publish",
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
Expand All @@ -47,24 +49,28 @@ def read(*rnames):
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: Jython",
"Programming Language :: Python :: Implementation :: PyPy",
"Framework :: Zope3",
"Topic :: Software Development :: Libraries :: Python Modules",
],

],
packages=find_packages('src'),
package_dir={'': 'src'},
namespace_packages=['zope',],
include_package_data=True,
install_requires=['setuptools'],
zip_safe=False,
test_suite='zope.event.tests.test_suite',
extras_require={'docs': ['Sphinx'],
'testing': ['nose', 'coverage'],
},
extras_require={
'docs': [
'Sphinx',
],
'test': [
'zope.testrunner',
],
},
)
2 changes: 1 addition & 1 deletion src/zope/__init__.py
@@ -1 +1 @@
__import__('pkg_resources').declare_namespace(__name__)
__import__('pkg_resources').declare_namespace(__name__) # pragma: no cover
2 changes: 1 addition & 1 deletion src/zope/event/tests.py
Expand Up @@ -53,7 +53,7 @@ def tearDownClassHandlers(test):

def test_suite():
return unittest.TestSuite((
unittest.makeSuite(Test_notify),
unittest.defaultTestLoader.loadTestsFromName(__name__),
doctest.DocTestSuite(
'zope.event.classhandler',
setUp=setUpClassHandlers, tearDown=tearDownClassHandlers)
Expand Down
32 changes: 19 additions & 13 deletions tox.ini
@@ -1,29 +1,35 @@
[tox]
envlist =
envlist =
# Jython 2.7b1 support pending fix for Jython incompat. w/ pip's vendored-in
# requests -> html5 libraries. See
# https://github.com/html5lib/html5lib-python/pull/150
# py27,py33,py34,pypy,pypy3,jython,coverage,docs
py27,py33,py34,py35,pypy,pypy3,coverage,docs
py27,py34,py35,py36,pypy,pypy3,coverage,docs

[testenv]
commands =
python setup.py -q test -q

[testenv:coverage]
basepython =
python2.7
commands =
nosetests --with-xunit --with-xcoverage
commands =
coverage run -m zope.testrunner --test-path=src []
deps =
nose
.[test]
coverage
nosexcover
setenv =
COVERAGE_FILE=.coverage.{envname}

[testenv:coverage]
setenv =
COVERAGE_FILE=.coverage
skip_install = true
commands =
coverage erase
coverage combine
coverage report
coverage html
coverage xml

[testenv:docs]
basepython =
python2.7
commands =
commands =
sphinx-build -b html -d docs/_build/doctrees docs docs/_build/html
sphinx-build -b doctest -d docs/_build/doctrees docs docs/_build/doctest
deps =
Expand Down

0 comments on commit c8110ad

Please sign in to comment.