testing/mozbase/mozrunner/tests/mozrunnertest.py

changeset 0
6474c204b198
equal deleted inserted replaced
-1:000000000000 0:9cf1c2f8042e
1 # This Source Code Form is subject to the terms of the Mozilla Public
2 # License, v. 2.0. If a copy of the MPL was not distributed with this file,
3 # You can obtain one at http://mozilla.org/MPL/2.0/.
4
5 import os
6 import unittest
7
8 import mozprofile
9 import mozrunner
10
11
12 @unittest.skipIf(not os.environ.get('BROWSER_PATH'),
13 'No binary has been specified.')
14 class MozrunnerTestCase(unittest.TestCase):
15
16 def setUp(self):
17 self.pids = []
18 self.threads = [ ]
19
20 self.profile = mozprofile.FirefoxProfile()
21 self.runner = mozrunner.FirefoxRunner(self.profile)
22
23 def tearDown(self):
24 for thread in self.threads:
25 thread.join()
26
27 self.runner.cleanup()
28
29 # Clean-up any left over and running processes
30 for pid in self.pids:
31 # TODO: Bug 925408
32 # mozprocess is not able yet to kill specific processes
33 pass

mercurial