Bug 1506310: Determine whether builds under test need signed extenions by release type; r=bc,ahal
authorTom Prince <mozilla@hocat.ca>
Tue, 20 Nov 2018 21:57:46 +0000
changeset 503813 b1bec3572f1786325e87ad11a0a6390d606743f8
parent 503812 a1fc429db01a944e5c805a7c5dc363cb9b380a56
child 503814 e947694d0ed75030968484df36f08a222cdd79b5
push id10290
push userffxbld-merge
push dateMon, 03 Dec 2018 16:23:23 +0000
treeherdermozilla-beta@700bed2445e6 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbc, ahal
bugs1506310
milestone65.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 1506310: Determine whether builds under test need signed extenions by release type; r=bc,ahal Differential Revision: https://phabricator.services.mozilla.com/D12077
taskcluster/ci/test/kind.yml
taskcluster/taskgraph/transforms/tests.py
--- a/taskcluster/ci/test/kind.yml
+++ b/taskcluster/ci/test/kind.yml
@@ -28,8 +28,19 @@ jobs-from:
     - marionette.yml
     - misc.yml
     - mochitest.yml
     - raptor.yml
     - reftest.yml
     - talos.yml
     - web-platform.yml
     - xpcshell.yml
+
+
+job-defaults:
+    require-signed-extensions:
+        by-release-type:
+            release|esr.*: true
+            beta:
+                by-test-platform:
+                    .*-devedition/.*: false
+                    default: true
+            default: false
--- a/taskcluster/taskgraph/transforms/tests.py
+++ b/taskcluster/taskgraph/transforms/tests.py
@@ -388,16 +388,21 @@ test_description_schema = Schema({
     # (not including the flavor) but can be overridden here.
     Exclusive(Optional('schedules-component'), 'optimization'): basestring,
 
     Optional('worker-type'): optionally_keyed_by(
         'test-platform',
         Any(basestring, None),
     ),
 
+    Optional(
+        'require-signed-extensions',
+        description="Whether the build being tested requires extensions be signed.",
+    ): optionally_keyed_by('release-type', 'test-platform', bool),
+
     # The target name, specifying the build artifact to be tested.
     # If None or not specified, a transform sets the target based on OS:
     # target.dmg (Mac), target.apk (Android), target.tar.bz2 (Linux),
     # or target.zip (Windows).
     Optional('target'): optionally_keyed_by(
         'test-platform',
         Any(basestring, None),
     ),
@@ -460,16 +465,17 @@ def set_defaults(config, tests):
         test.setdefault('max-run-time', 3600)
         test.setdefault('reboot', False)
         test.setdefault('virtualization', 'virtual')
         test.setdefault('loopback-audio', False)
         test.setdefault('loopback-video', False)
         test.setdefault('docker-image', {'in-tree': 'desktop1604-test'})
         test.setdefault('checkout', False)
         test.setdefault('serviceworker-e10s', False)
+        test.setdefault('require-signed-extensions', False)
 
         test['mozharness'].setdefault('extra-options', [])
         test['mozharness'].setdefault('requires-signed-builds', False)
         test['mozharness'].setdefault('tooltool-downloads', False)
         test['mozharness'].setdefault('set-moz-node-path', False)
         test['mozharness'].setdefault('chunked', False)
         test['mozharness'].setdefault('chunking-args', 'this-chunk')
         yield test
@@ -479,16 +485,29 @@ def set_defaults(config, tests):
 def validate(config, tests):
     for test in tests:
         validate_schema(test_description_schema, test,
                         "In test {!r}:".format(test['test-name']))
         yield test
 
 
 @transforms.add
+def resolve_keys(config, tests):
+    for test in tests:
+        resolve_keyed_by(
+            test, 'requite-signed-extensions',
+            item_name=test['test-name'],
+            **{
+                'release-type': config.params['release_type'],
+            }
+        )
+        yield test
+
+
+@transforms.add
 def setup_talos(config, tests):
     """Add options that are specific to talos jobs (identified by suite=talos)"""
     for test in tests:
         if test['suite'] not in ['talos', 'raptor']:
             yield test
             continue
 
         if test['suite'] == 'talos':
@@ -508,18 +527,17 @@ def setup_raptor(config, tests):
     """Add options that are specific to raptor jobs (identified by suite=raptor)"""
     for test in tests:
         if test['suite'] != 'raptor':
             yield test
             continue
 
         extra_options = test.setdefault('mozharness', {}).setdefault('extra-options', [])
 
-        if config.params['project'] in ('mozilla-beta', 'mozilla-release') or \
-           config.params['project'].startswith('mozilla-esr'):
+        if test['require-signed-extensions']:
             extra_options.append('--is-release-build')
 
         yield test
 
 
 @transforms.add
 def handle_artifact_prefix(config, tests):
     """Handle translating `artifact_prefix` appropriately"""