Bug 1403322 - schedule jsreftests inclusively; r=ahal
authorDustin J. Mitchell <dustin@mozilla.com>
Wed, 11 Oct 2017 17:31:20 +0000
changeset 385963 547109f6eb1d3c93cd60a59cf8d2293b6e0b08b4
parent 385962 5c50f100460ddff4fe000c3618b5540f00f9a025
child 385964 e3a310b6b896d401b66becff274c9f3c6898b096
push id96159
push userarchaeopteryx@coole-files.de
push dateFri, 13 Oct 2017 09:55:12 +0000
treeherdermozilla-inbound@5984d096f55c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersahal
bugs1403322
milestone58.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1403322 - schedule jsreftests inclusively; r=ahal This is just one flavor of the "reftets" suite, so we need to add a distinct scheduling component for it. MozReview-Commit-ID: AtKuvuUCk1l
js/moz.build
python/mozbuild/mozbuild/schedules.py
taskcluster/ci/test/tests.yml
taskcluster/taskgraph/transforms/tests.py
--- a/js/moz.build
+++ b/js/moz.build
@@ -8,12 +8,12 @@ with Files("**"):
 for header in ('GCAnnotations.h', 'GCAPI.h', 'HeapAPI.h', 'RootingAPI.h', 'SliceBudget.h', 'SweepingAPI.h', 'TraceKind.h', 'TracingAPI.h', 'WeakMapPtr.h', 'GCHashTable.h', 'GCPolicyAPI.h', 'GCVariant.h', 'GCVector.h'):
     with Files('public/' + header):
         BUG_COMPONENT = component_gc
 
 with Files('public/TrackedOptimizationInfo.h'):
     BUG_COMPONENT = component_jit
 
 with Files("src/**"):
-    SCHEDULES.inclusive += ['jittest']
+    SCHEDULES.inclusive += ['jittest', 'jsreftest']
 
 with Files("public/**"):
-    SCHEDULES.inclusive += ['jittest']
+    SCHEDULES.inclusive += ['jittest', 'jsreftest']
--- a/python/mozbuild/mozbuild/schedules.py
+++ b/python/mozbuild/mozbuild/schedules.py
@@ -10,18 +10,20 @@ skip-unless-schedules optimizations in t
 from __future__ import absolute_import, unicode_literals, print_function
 
 # TODO: ideally these lists could be specified in moz.build itself
 
 INCLUSIVE_COMPONENTS = [
     'py-lint',
     'js-lint',
     'yaml-lint',
-    # tests that only run when certain files have changed
+    # test suites that only run when certain files have changed
     'jittest',
+    # test flavors
+    'jsreftest',
 ]
 INCLUSIVE_COMPONENTS = sorted(INCLUSIVE_COMPONENTS)
 
 EXCLUSIVE_COMPONENTS = [
     # os families
     'android',
     'linux',
     'macosx',
--- a/taskcluster/ci/test/tests.yml
+++ b/taskcluster/ci/test/tests.yml
@@ -343,19 +343,17 @@ jsreftest:
                         macosx.*:
                             - unittests/mac_unittest.py
                         linux.*:
                             - unittests/linux_unittest.py
                             - remove_executables.py
                 extra-options:
                     - --reftest-suite=jsreftest
     when:
-        files-changed:
-            - js/src/**
-            - js/public/**
+        schedules: ['jsreftest']
     tier:
         by-test-platform:
             linux64-qr/.*: 1
             windows10-64-asan.*: 3
             default: default
 
 marionette:
     description: "Marionette unittest run"
--- a/taskcluster/taskgraph/transforms/tests.py
+++ b/taskcluster/taskgraph/transforms/tests.py
@@ -362,16 +362,19 @@ test_description_schema = Schema({
     'test-name': basestring,
 
     # the product name, defaults to firefox
     Optional('product'): basestring,
 
     # conditional files to determine when these tests should be run
     Optional('when'): Any({
         Optional('files-changed'): [basestring],
+
+        # SCHEDULES components; the test suite and platform family will be added automatically.
+        Optional('schedules'): [basestring],
     }),
 
     Optional('worker-type'): optionally_keyed_by(
         'test-platform',
         Any(basestring, None),
     ),
 
 }, required=True)
@@ -931,20 +934,23 @@ def make_job_description(config, tests):
         }
         jobdesc['treeherder'] = {
             'symbol': test['treeherder-symbol'],
             'kind': 'test',
             'tier': test['tier'],
             'platform': test.get('treeherder-machine-platform', test['build-platform']),
         }
 
-        if test.get('when'):
-            jobdesc['when'] = test['when']
+        when = test.get('when')
+        if when and 'files-changed' in when:
+            jobdesc['when'] = when
         else:
             schedules = [suite, platform_family(test['build-platform'])]
+            if when and 'schedules' in when:
+                schedules.extend(when['schedules'])
             if config.params['project'] != 'try':
                 # for non-try branches, include SETA
                 jobdesc['optimization'] = {'skip-unless-schedules-or-seta': schedules}
             else:
                 # otherwise just use skip-unless-schedules
                 jobdesc['optimization'] = {'skip-unless-schedules': schedules}
 
         run = jobdesc['run'] = {}