From 410b10925a152581870984cb6834a35914d6bbef Mon Sep 17 00:00:00 2001 From: Maja Frydrychowicz Date: Mon, 14 Mar 2016 11:24:58 -0400 Subject: [PATCH] Bug 1253618 - Support |skip-if = asan| manifest annotations in Marionette runner; r=automatedtester Obtain build info, including asan status, by looking up mozinfo.json. MozReview-Commit-ID: 8XWMGtBEbKL --HG-- extra : rebase_source : f474341433510bd659b4c1d2bc035eec73b603fc --- .../marionette/harness/marionette/runner/base.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/testing/marionette/harness/marionette/runner/base.py b/testing/marionette/harness/marionette/runner/base.py index f2ca48eaf6bd..9013c0fabb2a 100644 --- a/testing/marionette/harness/marionette/runner/base.py +++ b/testing/marionette/harness/marionette/runner/base.py @@ -32,6 +32,19 @@ import httpd here = os.path.abspath(os.path.dirname(__file__)) +def update_mozinfo(path=None): + """walk up directories to find mozinfo.json and update the info""" + + path = path or here + dirs = set() + while path != os.path.expanduser('~'): + if path in dirs: + break + dirs.add(path) + path = os.path.split(path)[0] + + return mozinfo.find_and_update_from_json(*dirs) + class MarionetteTest(TestResult): @@ -1001,6 +1014,8 @@ setReq.onerror = function() { if self.test_tags: filters.append(tags(self.test_tags)) e10s = self.appinfo.get('browserTabsRemoteAutostart', False) + json_path = update_mozinfo(filepath) + self.logger.info("mozinfo updated with the following: {}".format(None)) manifest_tests = manifest.active_tests(exists=False, disabled=True, filters=filters,