| Index: scripts/slave/recipe_modules/chromium/example.expected/amp_split_recipe.json
|
| diff --git a/scripts/slave/recipes/chromium.expected/full_chromium_fyi_Android_Builder__dbg_.json b/scripts/slave/recipe_modules/chromium/example.expected/amp_split_recipe.json
|
| similarity index 68%
|
| copy from scripts/slave/recipes/chromium.expected/full_chromium_fyi_Android_Builder__dbg_.json
|
| copy to scripts/slave/recipe_modules/chromium/example.expected/amp_split_recipe.json
|
| index c6fdd85208c00909030012f691f038cf45f9d4b4..5bc276cd65cbe3327fc561b6be05c8d5ebd34501 100644
|
| --- a/scripts/slave/recipes/chromium.expected/full_chromium_fyi_Android_Builder__dbg_.json
|
| +++ b/scripts/slave/recipe_modules/chromium/example.expected/amp_split_recipe.json
|
| @@ -7,9 +7,9 @@
|
| "--master",
|
| "chromium.fyi",
|
| "--builder",
|
| - "Android Builder (dbg)",
|
| + "Android Tests (amp split)",
|
| "--slave",
|
| - "TestSlavename",
|
| + "build1-a1",
|
| "--spec",
|
| "cache_dir = None\nsolutions = [{'custom_vars': {'googlecode_url': 'svn://svn-mirror.golo.chromium.org/%s', 'nacl_trunk': 'svn://svn-mirror.golo.chromium.org/native_client/trunk', 'sourceforge_url': 'svn://svn-mirror.golo.chromium.org/%(repo)s', 'webkit_trunk': 'svn://svn-mirror.golo.chromium.org/blink/trunk'}, 'deps_file': 'DEPS', 'managed': True, 'name': 'src', 'url': 'svn://svn-mirror.golo.chromium.org/chrome/trunk/src'}]\ntarget_os = ['android']",
|
| "--root",
|
| @@ -101,11 +101,11 @@
|
| "/path/to/tmp/json",
|
| "--",
|
| "--build-config-fs",
|
| - "Debug",
|
| + "Release",
|
| "--paths",
|
| "{\"build\": \"[BUILD]\", \"checkout\": \"[SLAVE_BUILD]/src\"}",
|
| "--properties",
|
| - "{\"buildername\": \"Android Builder (dbg)\", \"buildnumber\": 571, \"mastername\": \"chromium.fyi\", \"slavename\": \"TestSlavename\", \"target_platform\": \"android\"}"
|
| + "{\"buildername\": \"Android Tests (amp split)\", \"buildnumber\": \"77457\", \"mastername\": \"chromium.fyi\", \"slavename\": \"build1-a1\", \"target_platform\": \"android\"}"
|
| ],
|
| "cwd": "[SLAVE_BUILD]",
|
| "name": "get compile targets for scripts",
|
| @@ -118,93 +118,105 @@
|
| "cmd": [
|
| "python",
|
| "-u",
|
| - "[BUILD]/scripts/slave/cleanup_temp.py"
|
| + "[BUILD]/scripts/slave/compile.py",
|
| + "--target",
|
| + "Release",
|
| + "--src-dir",
|
| + "[SLAVE_BUILD]/src",
|
| + "--build-tool",
|
| + "ninja",
|
| + "--compiler",
|
| + "goma",
|
| + "--out-dir",
|
| + "/tmp",
|
| + "--goma-dir",
|
| + "[BUILD]/goma",
|
| + "--",
|
| + "All"
|
| ],
|
| "cwd": "[SLAVE_BUILD]",
|
| - "name": "cleanup_temp"
|
| + "env": {
|
| + "PATH": "[SLAVE_BUILD]/src/third_party/android_tools/sdk/platform-tools:[SLAVE_BUILD]/src/build/android:%(PATH)s"
|
| + },
|
| + "name": "compile"
|
| },
|
| {
|
| "cmd": [
|
| "python",
|
| "-u",
|
| - "\nimport shutil, sys, os\nshutil.rmtree(sys.argv[1], True)\nshutil.rmtree(sys.argv[2], True)\ntry:\n os.remove(sys.argv[3])\nexcept OSError:\n pass\nfor base, _dirs, files in os.walk(sys.argv[4]):\n for f in files:\n if f.endswith('.pyc'):\n os.remove(os.path.join(base, f))\n",
|
| - "[SLAVE_BUILD]/src/out/Debug/debug_info_dumps",
|
| - "[SLAVE_BUILD]/src/out/Debug/test_logs",
|
| - "[SLAVE_BUILD]/src/out/build_product.zip",
|
| - "[SLAVE_BUILD]/src"
|
| + "\nimport os, sys\nfrom common import chromium_utils\n\nif os.path.exists(sys.argv[1]):\n chromium_utils.RemoveDirectory(sys.argv[1])\n",
|
| + "[SLAVE_BUILD]/src/out/Release"
|
| ],
|
| "cwd": "[SLAVE_BUILD]",
|
| - "name": "clean local files",
|
| + "name": "rmtree build directory",
|
| "~followup_annotations": [
|
| "@@@STEP_LOG_LINE@python.inline@@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@import shutil, sys, os@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@shutil.rmtree(sys.argv[1], True)@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@shutil.rmtree(sys.argv[2], True)@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@try:@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@ os.remove(sys.argv[3])@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@except OSError:@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@ pass@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@for base, _dirs, files in os.walk(sys.argv[4]):@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@ for f in files:@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@ if f.endswith('.pyc'):@@@",
|
| - "@@@STEP_LOG_LINE@python.inline@ os.remove(os.path.join(base, f))@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@import os, sys@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@from common import chromium_utils@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@if os.path.exists(sys.argv[1]):@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@ chromium_utils.RemoveDirectory(sys.argv[1])@@@",
|
| "@@@STEP_LOG_END@python.inline@@@"
|
| ]
|
| },
|
| {
|
| - "allow_subannotations": false,
|
| "cmd": [
|
| - "[SLAVE_BUILD]/src/build/tree_truth.sh",
|
| - "[SLAVE_BUILD]/src",
|
| - "src"
|
| + "python",
|
| + "-u",
|
| + "[BUILD]/scripts/slave/extract_build.py",
|
| + "--target",
|
| + "Release",
|
| + "--build-archive-url",
|
| + "gs://test-domain/test-archive.zip",
|
| + "--factory-properties",
|
| + "{\"buildername\": \"Android Tests (amp split)\", \"buildnumber\": \"77457\", \"mastername\": \"chromium.fyi\", \"parent_build_archive_url\": \"gs://test-domain/test-archive.zip\", \"recipe\": \"chromium:example\", \"slavename\": \"build1-a1\"}",
|
| + "--build-properties",
|
| + "{\"buildername\": \"Android Tests (amp split)\", \"buildnumber\": \"77457\", \"mastername\": \"chromium.fyi\", \"parent_build_archive_url\": \"gs://test-domain/test-archive.zip\", \"recipe\": \"chromium:example\", \"slavename\": \"build1-a1\"}"
|
| ],
|
| "cwd": "[SLAVE_BUILD]",
|
| - "name": "tree truth steps"
|
| + "name": "extract build"
|
| },
|
| {
|
| "cmd": [
|
| "python",
|
| "-u",
|
| - "[BUILD]/scripts/slave/compile.py",
|
| - "--target",
|
| - "Debug",
|
| - "--src-dir",
|
| - "[SLAVE_BUILD]/src",
|
| - "--build-tool",
|
| - "ninja",
|
| - "--compiler",
|
| - "goma",
|
| - "--goma-dir",
|
| - "[BUILD]/goma",
|
| - "--",
|
| - "base_junit_tests",
|
| - "components_browsertests_apk",
|
| - "gfx_unittests_apk"
|
| + "RECIPE_MODULE[adb]/resources/list_devices.py",
|
| + "['[SLAVE_BUILD]/src/third_party/android_tools/sdk/platform-tools/adb', 'devices']",
|
| + "/path/to/tmp/json"
|
| ],
|
| "cwd": "[SLAVE_BUILD]",
|
| - "env": {
|
| - "PATH": "[SLAVE_BUILD]/src/third_party/android_tools/sdk/platform-tools:[SLAVE_BUILD]/src/build/android:%(PATH)s"
|
| - },
|
| - "name": "compile"
|
| + "name": "List adb devices",
|
| + "~followup_annotations": [
|
| + "@@@STEP_LOG_LINE@json.output@[@@@",
|
| + "@@@STEP_LOG_LINE@json.output@ \"014E1F310401C009\"@@@",
|
| + "@@@STEP_LOG_LINE@json.output@]@@@",
|
| + "@@@STEP_LOG_END@json.output@@@"
|
| + ]
|
| },
|
| {
|
| - "allow_subannotations": true,
|
| "cmd": [
|
| "python",
|
| "-u",
|
| - "[BUILD]/scripts/slave/zip_build.py",
|
| - "--target",
|
| - "Debug",
|
| - "--build-url",
|
| - "gs://chromium-fyi-archive/chromium.fyi/Android Builder (dbg)",
|
| - "--build_revision",
|
| - "f27fede2220bcd326aee3e86ddfd4ebd0fe58cb9",
|
| - "--factory-properties",
|
| - "{\"blamelist\": [\"cool_dev1337@chromium.org\", \"hax@chromium.org\"], \"buildername\": \"Android Builder (dbg)\", \"buildnumber\": 571, \"mastername\": \"chromium.fyi\", \"parent_buildername\": null, \"recipe\": \"chromium\", \"slavename\": \"TestSlavename\", \"workdir\": \"/path/to/workdir/TestSlavename\"}",
|
| - "--build-properties",
|
| - "{\"blamelist\": [\"cool_dev1337@chromium.org\", \"hax@chromium.org\"], \"buildername\": \"Android Builder (dbg)\", \"buildnumber\": 571, \"mastername\": \"chromium.fyi\", \"parent_buildername\": null, \"recipe\": \"chromium\", \"slavename\": \"TestSlavename\", \"workdir\": \"/path/to/workdir/TestSlavename\"}"
|
| + "\nimport subprocess\nimport sys\nadb_path = sys.argv[1]\nfor device in sys.argv[2:]:\n subprocess.check_call([adb_path, '-s', device, 'root'])\n subprocess.check_call([adb_path, '-s', device, 'wait-for-device'])\n",
|
| + "[SLAVE_BUILD]/src/third_party/android_tools/sdk/platform-tools/adb",
|
| + "014E1F310401C009"
|
| ],
|
| "cwd": "[SLAVE_BUILD]",
|
| - "name": "package build"
|
| + "name": "Root devices",
|
| + "~followup_annotations": [
|
| + "@@@STEP_LOG_LINE@python.inline@@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@import subprocess@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@import sys@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@adb_path = sys.argv[1]@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@for device in sys.argv[2:]:@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@ subprocess.check_call([adb_path, '-s', device, 'root'])@@@",
|
| + "@@@STEP_LOG_LINE@python.inline@ subprocess.check_call([adb_path, '-s', device, 'wait-for-device'])@@@",
|
| + "@@@STEP_LOG_END@python.inline@@@"
|
| + ]
|
| + },
|
| + {
|
| + "name": "$final_result",
|
| + "reason": "cannot specify both device_minimum_os and device_os",
|
| + "status_code": 1
|
| }
|
| ]
|
|
|