Skip to content

Commit

Permalink
add teardown to fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
pbauer committed Nov 2, 2014
1 parent 6d2d568 commit d4b269b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion plone/app/contenttypes/tests/test_document.py
Expand Up @@ -22,7 +22,7 @@

from plone.app.testing import TEST_USER_ID, setRoles
from plone.app.z3cform.interfaces import IPloneFormLayer

import transaction

class DocumentIntegrationTest(unittest.TestCase):

Expand Down Expand Up @@ -85,6 +85,11 @@ def test_view(self):
self.assertTrue('This is my document.' in view())
self.assertTrue('Lorem ipsum' in view())

def tearDown(self):
if 'document' in self.portal.objectIds():
self.portal.manage_delObjects(ids='document')
transaction.commit()


class DocumentFunctionalTest(unittest.TestCase):

Expand Down

0 comments on commit d4b269b

Please sign in to comment.