Skip to content

Commit 74117bd

Browse files
committed
Bug 1609508 - Adjust test-info report queries; r=jmaher
Minor changes to test-info report's interaction with ActiveData: - with improved reftest data in ActiveData, several path modifications can be removed; - adjust some crashtest query data ranges to more efficiently handle the new data; - add a missing path modification for xpcshell, to handle test names that include manifests. Differential Revision: https://phabricator.services.mozilla.com/D60551 --HG-- extra : moz-landing-system : lando
1 parent 85c420c commit 74117bd

File tree

1 file changed

+9
-20
lines changed

1 file changed

+9
-20
lines changed

testing/testinfo.py

Lines changed: 9 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -663,17 +663,11 @@ def path_mod_reftest(self, path):
663663
path = path.split('?')[0]
664664
# "<path>#<fragment>" -> "<path>"
665665
path = path.split('#')[0]
666-
# "chrome://reftest/content/<path>" -> "layout/reftests/<path>"
667-
path = path.replace('chrome://reftest/content', 'layout/reftests')
668666
return path
669667

670668
def path_mod_jsreftest(self, path):
671-
# "<path-to>/jsreftest.html?test=<path>" -> "<path>"
672-
path = path.split('=')[1]
673669
# "<path>;assert" -> "<path>"
674670
path = path.split(';')[0]
675-
# "<rel-path>" -> "js/src/tests/<path>"
676-
path = os.path.join('js', 'src', 'tests', path)
677671
return path
678672

679673
def path_mod_marionette(self, path):
@@ -683,16 +677,6 @@ def path_mod_marionette(self, path):
683677
path = path.replace('\\', os.path.sep)
684678
return path
685679

686-
def path_mod_crashtest(self, path):
687-
# TODO: revisit the need for these transforms after bug 1596567
688-
# "chrome://reftest/content/crashtests/<path>" -> "<path>"
689-
path = path.replace('chrome://reftest/content/crashtests/', '')
690-
# "file://<path2>/reftests/tests/<path>" -> "<path>"
691-
path = re.sub(r'file://.*/reftest/tests/', '', path)
692-
# "http://<ip>/tests/<path>" -> "<path>"
693-
path = re.sub(r'http://\d*\.\d*\.\d*\.\d*:\d*/tests/', '', path)
694-
return path
695-
696680
def path_mod_wpt(self, path):
697681
if path[0] == os.path.sep:
698682
# "/<path>" -> "<path>"
@@ -709,6 +693,11 @@ def path_mod_jittest(self, path):
709693
# "<path>" -> "js/src/jit-test/tests/<path>"
710694
return os.path.join('js', 'src', 'jit-test', 'tests', path)
711695

696+
def path_mod_xpcshell(self, path):
697+
# <manifest>.ini:<path> -> "<path>"
698+
path = path.split('.ini:')[-1]
699+
return path
700+
712701
def add_activedata(self, branches, days, by_component):
713702
suites = {
714703
# List of known suites requiring special path handling and/or
@@ -726,12 +715,12 @@ def add_activedata(self, branches, days, by_component):
726715
"web-platform-tests-reftests": (self.path_mod_wpt,
727716
[{"regex": {"result.test": "/css/css-.*"}},
728717
{"not": {"regex": {"result.test": "/css/css-.*"}}}]),
729-
"crashtest": (self.path_mod_crashtest,
730-
[{"regex": {"result.test": ".*/tests/[a-m].*"}},
731-
{"not": {"regex": {"result.test": ".*/tests/[a-m].*"}}}]),
718+
"crashtest": (None,
719+
[{"regex": {"result.test": "[a-g].*"}},
720+
{"not": {"regex": {"result.test": "[a-g].*"}}}]),
732721
"web-platform-tests-wdspec": (self.path_mod_wpt, [None]),
733722
"web-platform-tests-crashtests": (self.path_mod_wpt, [None]),
734-
"xpcshell": (None, [None]),
723+
"xpcshell": (self.path_mod_xpcshell, [None]),
735724
"mochitest-plain": (None, [None]),
736725
"mochitest-browser-chrome": (None, [None]),
737726
"mochitest-media": (None, [None]),

0 commit comments

Comments
 (0)