Skip to content

Commit

Permalink
Remove the ZOPETESTCASEALERT as it imports from ZopeTestCase and …
Browse files Browse the repository at this point in the history
…has side effects.

Fixes #64.
  • Loading branch information
thet committed Jul 1, 2019
1 parent 364f978 commit e078a54
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
3 changes: 3 additions & 0 deletions news/67.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Remove the ``ZOPETESTCASEALERT`` as it imports from ZopeTestCase and has side effects.
Fixes #64.
[thet]
6 changes: 0 additions & 6 deletions src/plone/testing/zope.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
from plone.testing import zca
from plone.testing import zodb
from plone.testing._z2_testbrowser import Browser # noqa
from Testing.ZopeTestCase.ZopeLite import _patched as ZOPETESTCASEALERT
from webtest.http import StopableWSGIServer
from Zope2.App.schema import Zope2VocabularyRegistry
from zope.schema.vocabulary import getVocabularyRegistry
Expand Down Expand Up @@ -461,11 +460,6 @@ def setUpDatabase(self):
that the database that is opened by Zope 2 is in fact the top of
the resource stack.
"""
if ZOPETESTCASEALERT:
raise Exception('You try to run plone.testing tests together with '
'ZopeTestCase tests. This will result in random '
'failures. Convert the ZopeTestCase Tests or '
'do not run them together')

import Zope2.Startup.datatypes
import App.config
Expand Down

0 comments on commit e078a54

Please sign in to comment.