-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
25 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,29 @@ | ||
import unittest2 as unittest | ||
from collective.linguaanalytics.tests import base | ||
from plone.browserlayer import utils | ||
|
||
class TestSetup(base.IntegrationTestCase): | ||
"""We tests the setup (install) of the addons. You should check all | ||
stuff in profile are well activated (browserlayer, js, content types, ...) | ||
""" | ||
|
||
def test_xxx(self): | ||
self.assertTrue(False) | ||
def test_browserlayer(self): | ||
from collective.linguaanalytics.interfaces import ILayer | ||
layers = utils.registered_layers() | ||
self.assertIn(ILayer, layers) | ||
|
||
class TestUninstall(base.IntegrationTestCase): | ||
"""Test if the addon uninstall well""" | ||
|
||
def setUp(self): | ||
super(TestUninstall, self).setUp() | ||
qi = self.portal['portal_quickinstaller'] | ||
qi.uninstallProducts(products=['collective.linguaanalytics']) | ||
|
||
def test_uninstall_browserlayer(self): | ||
from collective.linguaanalytics.interfaces import ILayer | ||
layers = utils.registered_layers() | ||
self.assertNotIn(ILayer, layers) | ||
|
||
def test_suite(): | ||
return unittest.defaultTestLoader.loadTestsFromName(__name__) |