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
--- a/testing/marionette/harness/marionette/runner/base.py
+++ b/testing/marionette/harness/marionette/runner/base.py
@@ -27,16 +27,29 @@ from moztest.adapters.unit import Struct
from moztest.results import TestResultCollection, TestResult, relevant_line
import mozversion
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):
@property
def test_name(self):
if self.test_class is not None:
return '%s.py %s.%s' % (self.test_class.split('.')[0],
self.test_class,
@@ -996,16 +1009,18 @@ setReq.onerror = function() {
if file_ext == '.ini':
manifest = TestManifest()
manifest.read(filepath)
filters = []
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,
device=self.device,
app=self.appName,
e10s=e10s,
**mozinfo.info)
if len(manifest_tests) == 0: