@@ -37,44 +37,44 @@ logger = logging.getLogger(__name__)
3737
3838
3939class UpstartIntegrationTests(UnityTestCase):
40−
40+
4141 scenarios = _get_device_emulation_scenarios()
42−
42+
4343 def _get_status(self):
4444 pid, status = os.waitpid(self.process.pid, os.WUNTRACED | os.WCONTINUED | os.WNOHANG)
4545 logger.debug("Got status: {0}; stopped: {1}; continued: {2}"\
4646 .format(status, os.WIFSTOPPED(status), os.WIFCONTINUED(status)))
4747 return status
48−
48+
4949 def _launch_unity(self):
5050 self.patch_environment("QT_LOAD_TESTABILITY", "1")
5151 self.process = subprocess.Popen([get_binary_path()] + self.unity_geometry_args)
5252 self.addCleanup(lambda: self.process.kill())
53−
53+
5454 def _set_proxy(self):
5555 super(UpstartIntegrationTests, self)._set_proxy(get_proxy_object_for_existing_process(
5656 pid=self.process.pid,
5757 emulator_base=UnityEmulatorBase,
5858 ))
59−
59+
6060 def test_no_sigstop(self):
6161 self.patch_environment("UPSTART_JOB", "foo")
6262 self._launch_unity()
6363 self._set_proxy()
64−
64+
6565 logger.debug("Unity started, waiting for it to be ready.")
6666 self.assertUnityReady()
6767 logger.debug("Unity loaded and ready.")
68−
68+
6969 def test_expect_sigstop(self):
7070 self.patch_environment("UPSTART_JOB", "unity8")
7171 self._launch_unity()
7272 self.assertThat(lambda: os.WIFSTOPPED(self._get_status()), Eventually(Equals(True)), "Unity8 should raise SIGSTOP when ready")
73−
73+
7474 self.process.send_signal(signal.SIGCONT)
7575 self.assertThat(lambda: os.WIFCONTINUED(self._get_status()), Eventually(Equals(True)), "Unity8 should have resumed")
76−
76+
7777 logger.debug("Unity started, waiting for it to be ready.")
7878 self._set_proxy()
7979 self.assertUnityReady()
80− logger.debug("Unity loaded and ready.")
80+ logger.debug("Unity loaded and ready.")