[Pkg-mozext-commits] [requestpolicy] 50/65: [tst][fix] test_multiple_installations: No assertions in setUp
David Prévot
taffit at moszumanska.debian.org
Fri Mar 25 22:59:50 UTC 2016
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository requestpolicy.
commit 447bf10167cfefe09e9f368b80a6589479da9d55
Author: Martin Kimmerle <dev at 256k.de>
Date: Tue Feb 2 12:34:47 2016 +0100
[tst][fix] test_multiple_installations: No assertions in setUp
If an assertion in setUp() fails, tearDown() won't be called.
---
.../test_multiple_installations.py | 16 ++++------------
1 file changed, 4 insertions(+), 12 deletions(-)
diff --git a/tests/marionette/tests/addon_install_and_upgrade/test_multiple_installations.py b/tests/marionette/tests/addon_install_and_upgrade/test_multiple_installations.py
index a0e1f5f..55eb9cf 100644
--- a/tests/marionette/tests/addon_install_and_upgrade/test_multiple_installations.py
+++ b/tests/marionette/tests/addon_install_and_upgrade/test_multiple_installations.py
@@ -103,22 +103,18 @@ class CommonTests:
"""
class OtherVersionActive_ThenInstallCurrentVersion(MultipleInstallationsTestCase):
- def setUp(self):
- MultipleInstallationsTestCase.setUp(self)
+ def test_notice_is_shown(self):
self.rp_addon.uninstall()
self.other_rp.install()
- def test_notice_is_shown(self):
self.rp_addon.install()
self._assert_notice_tab()
class OtherVersionActive_ThenEnableCurrentVersion(MultipleInstallationsTestCase):
- def setUp(self):
- MultipleInstallationsTestCase.setUp(self)
+ def test_notice_is_shown(self):
self.rp_addon.disable()
self.other_rp.install()
- def test_notice_is_shown(self):
self.rp_addon.enable()
self._assert_notice_tab()
@@ -128,8 +124,7 @@ class CommonTests:
self._assert_notice_tab()
class OtherVersionNotActive_ThenEnable(MultipleInstallationsTestCase):
- def setUp(self):
- MultipleInstallationsTestCase.setUp(self)
+ def test_notice_is_shown(self):
# After this preparation, both the current and the old version
# will be installed, but the old version will be disabled.
self.rp_addon.disable()
@@ -140,17 +135,14 @@ class CommonTests:
msg=("No 'notice' tab has been opened during "
"preparation"))
- def test_notice_is_shown(self):
self.other_rp.enable()
self._assert_notice_tab()
class OtherAndCurrentVersionActiveAfterRestart(MultipleInstallationsTestCase):
- def setUp(self):
- MultipleInstallationsTestCase.setUp(self)
+ def test_notice_is_shown(self):
self.other_rp.install()
self._close_notice_tabs()
- def test_notice_is_shown(self):
self.restart()
# Don't require the tab to be selected. It somehow doesn't get
# selected in the unit test, but it works when done manually.
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/requestpolicy.git
More information about the Pkg-mozext-commits
mailing list