Move setting AT_SPI_CLIENT to discover
It needs to be called as early as possible before unit tests has a chance to import gtk. Hopefully will fix random test failures we are seeing in buildbot.
This commit is contained in:
parent
6d319619f0
commit
f54229efd2
@ -37,6 +37,7 @@ def main():
|
||||
|
||||
os.chdir(args.tests_dir)
|
||||
os.environ["TMPDIR"] = temp_dir
|
||||
os.environ["AT_SPI_CLIENT"] = "yes"
|
||||
|
||||
try:
|
||||
test = unittest.defaultTestLoader.discover(".")
|
||||
|
@ -35,14 +35,10 @@ class UITestCase(unittest.TestCase):
|
||||
self._orig_level = logger.getEffectiveLevel()
|
||||
logger.setLevel(logging.DEBUG)
|
||||
|
||||
os.environ["AT_SPI_CLIENT"] = "yes"
|
||||
|
||||
def tearDown(self):
|
||||
logger = logging.getLogger()
|
||||
logger.setLevel(self._orig_level)
|
||||
|
||||
del os.environ["AT_SPI_CLIENT"]
|
||||
|
||||
@contextmanager
|
||||
def run_view(self, name):
|
||||
view_path = os.path.join("views", "%s.py" % name)
|
||||
|
Loading…
Reference in New Issue
Block a user