summaryrefslogtreecommitdiffstats
path: root/build/isolate.gypi
diff options
context:
space:
mode:
authormaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-10-20 04:16:31 +0000
committermaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-10-20 04:16:31 +0000
commit88494710ef505cc02aef5b51f2340b4d53508310 (patch)
tree4125810ffaed45a5a662b0162b288102426328a8 /build/isolate.gypi
parent0f75d3099bfcf1b6405153cd6ec6b12d1348c98a (diff)
downloadchromium_src-88494710ef505cc02aef5b51f2340b4d53508310.zip
chromium_src-88494710ef505cc02aef5b51f2340b4d53508310.tar.gz
chromium_src-88494710ef505cc02aef5b51f2340b4d53508310.tar.bz2
Convert all the foo_test_run from using actions to use rules.
This removes a lot of the duplication of the exact details about how to run isolate.py exactly.. This will permit inserting arbitrary command line arguments eventually, for --subdir support. TBR=csharp@chromium.org BUG= Review URL: https://chromiumcodereview.appspot.com/11236005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@163144 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build/isolate.gypi')
-rw-r--r--build/isolate.gypi61
1 files changed, 61 insertions, 0 deletions
diff --git a/build/isolate.gypi b/build/isolate.gypi
new file mode 100644
index 0000000..38d8ef3
--- /dev/null
+++ b/build/isolate.gypi
@@ -0,0 +1,61 @@
+# Copyright (c) 2012 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+# This file is meant to be included into a target to provide a rule
+# to "build" .isolate files into a .isolated file.
+#
+# To use this, create a gyp target with the following form:
+# 'conditions': [
+# ['test_isolation_mode != "noop"', {
+# 'targets': [
+# {
+# 'target_name': 'foo_test_run',
+# 'type': 'none',
+# 'dependencies': [
+# 'foo_test',
+# ],
+# 'includes': [
+# '../build/isolate.gypi',
+# 'foo_test.isolate',
+# ],
+# 'sources': [
+# 'foo_test.isolate',
+# ],
+# },
+# ],
+# }],
+# ],
+#
+# Note: foo_test.isolate is included and a source file. It is an inherent
+# property of the .isolate format. This permits to define GYP variables but is
+# a stricter format than GYP so isolate.py can read it.
+#
+# The generated .isolated file will be:
+# <(PRODUCT_DIR)/foo_test.isolated
+
+{
+ 'rules': [
+ {
+ 'rule_name': 'isolate',
+ 'extension': 'isolate',
+ 'inputs': [
+ '<@(isolate_dependency_tracked)',
+ '<(RULE_INPUT_PATH)',
+ ],
+ 'outputs': [
+ '<(PRODUCT_DIR)/<(RULE_INPUT_ROOT).isolated',
+ ],
+ 'action': [
+ '<(DEPTH)/tools/swarm_client/isolate.py',
+ '<(test_isolation_mode)',
+ '--outdir', '<(test_isolation_outdir)',
+ '--variable', 'PRODUCT_DIR', '<(PRODUCT_DIR)',
+ '--variable', 'OS', '<(OS)',
+ '--result', '<@(_outputs)',
+ '--isolate', '<(RULE_INPUT_PATH)',
+ ],
+ 'msvs_cygwin_shell': 0,
+ },
+ ],
+}