Commit aa8d15d0 authored by Jason Madden's avatar Jason Madden

Add tox environments for testing ZODB integration and ZODB integration in...

Add tox environments for testing ZODB integration and ZODB integration in pure-python mode; run one of these environments on Travis. This reveals a bug in the new ContainedProxy object: it must be weakly referencable to go in the picklecache, so make that possible.
parent 1ccd8867
...@@ -6,6 +6,7 @@ env: ...@@ -6,6 +6,7 @@ env:
- TOXENV=pypy - TOXENV=pypy
- TOXENV=py33 - TOXENV=py33
- TOXENV=py34 - TOXENV=py34
- TOXENV=py27-pure-zodb
install: install:
- pip install tox - pip install tox
script: script:
......
...@@ -35,7 +35,7 @@ def _special_name(name): ...@@ -35,7 +35,7 @@ def _special_name(name):
class PyContainedProxyBase(AbstractPyProxyBase, Persistent): class PyContainedProxyBase(AbstractPyProxyBase, Persistent):
"""Persistent proxy """Persistent proxy
""" """
__slots__ = ('_wrapped', '__parent__', '__name__') __slots__ = ('_wrapped', '__parent__', '__name__', '__weakref__')
def __new__(cls, obj): def __new__(cls, obj):
inst = super(PyContainedProxyBase, cls).__new__(cls, obj) inst = super(PyContainedProxyBase, cls).__new__(cls, obj)
......
[tox] [tox]
envlist = py26,py27,pypy,py33,py34,docs envlist = py26,py27,pypy,py33,py34,py27-zodb,pypy-zodb,py27-pure-zodb,docs
[testenv] [testenv]
commands = python setup.py -q test -q commands = python setup.py -q test -q
...@@ -23,6 +23,29 @@ deps = ...@@ -23,6 +23,29 @@ deps =
zope.testrunner zope.testrunner
zope.testing zope.testing
[testenv:py27-zodb]
basepython =
python2.7
deps =
{[testenv]deps}
ZODB
[testenv:py27-pure-zodb]
basepython =
python2.7
setenv =
PURE_PYTHON = 1
deps =
{[testenv]deps}
ZODB
[testenv:pypy-zodb]
basepython =
pypy
deps =
{[testenv]deps}
ZODB
[testenv:coverage] [testenv:coverage]
usedevelop = true usedevelop = true
basepython = basepython =
...@@ -38,7 +61,7 @@ deps = ...@@ -38,7 +61,7 @@ deps =
[testenv:docs] [testenv:docs]
basepython = basepython =
python2.7 python2.7
commands = commands =
sphinx-build -b html -d docs/_build/doctrees docs docs/_build/html sphinx-build -b html -d docs/_build/doctrees docs docs/_build/html
sphinx-build -b doctest -d docs/_build/doctrees docs docs/_build/doctest sphinx-build -b doctest -d docs/_build/doctrees docs docs/_build/doctest
deps = deps =
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment