From fbfa601efda3f683e305ff9c82873dd017e11b82 Mon Sep 17 00:00:00 2001 From: agable Date: Tue, 6 Sep 2016 18:10:22 -0700 Subject: [PATCH] Remove svn from gclient recipe module example R=martiniss@chromium.org BUG=640251 Review-Url: https://codereview.chromium.org/2318843002 --- recipe_modules/gclient/api.py | 4 ++-- .../gclient/example.expected/basic.json | 16 ++++++++-------- .../gclient/example.expected/revision.json | 18 ++++++++++-------- .../gclient/example.expected/tryserver.json | 18 ++++++++++-------- recipe_modules/gclient/example.py | 11 ++++------- 5 files changed, 34 insertions(+), 33 deletions(-) diff --git a/recipe_modules/gclient/api.py b/recipe_modules/gclient/api.py index 9182d6a1f..ab1a54ad0 100644 --- a/recipe_modules/gclient/api.py +++ b/recipe_modules/gclient/api.py @@ -133,8 +133,8 @@ class GclientApi(recipe_api.RecipeApi): revisions = [] self.set_patch_project_revision(self.m.properties.get('patch_project'), cfg) for i, s in enumerate(cfg.solutions): - if s.safesync_url: # prefer safesync_url in gclient mode - continue + if s.safesync_url: # pragma: no cover + continue # prefer safesync_url in gclient mode if i == 0 and s.revision is None: s.revision = RevisionFallbackChain() diff --git a/recipe_modules/gclient/example.expected/basic.json b/recipe_modules/gclient/example.expected/basic.json index c52cde02c..bccc96607 100644 --- a/recipe_modules/gclient/example.expected/basic.json +++ b/recipe_modules/gclient/example.expected/basic.json @@ -85,13 +85,13 @@ "RECIPE_PACKAGE_REPO[depot_tools]/gclient.py", "config", "--spec", - "cache_dir = '[GIT_CACHE]'\nsolutions = [{'deps_file': '.DEPS.git', 'managed': True, 'name': 'WebKit', 'safesync_url': 'https://blink-status.appspot.com/lkgr', 'url': 'svn://svn.chromium.org/blink/trunk'}]" + "cache_dir = '[GIT_CACHE]'\nsolutions = [{'deps_file': '.DEPS.git', 'managed': True, 'name': 'Angle', 'url': 'https://chromium.googlesource.com/angle/angle.git'}]" ], "cwd": "[SLAVE_BUILD]/src/third_party", "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient setup" + "name": "[spec: Angle] gclient setup" }, { "cmd": [ @@ -109,7 +109,7 @@ "--no-nag-max", "--delete_unversioned_trees", "--revision", - "third_party/WebKit@123", + "src/third_party/angle@refs/heads/lkgr", "--output-json", "/path/to/tmp/json" ], @@ -117,12 +117,12 @@ "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient sync", + "name": "[spec: Angle] gclient sync", "~followup_annotations": [ "@@@STEP_LOG_LINE@json.output@{@@@", "@@@STEP_LOG_LINE@json.output@ \"solutions\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"WebKit/\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"revision\": \"3eebce6ea96f9e6c03e9252a4f8ef2ea9fe141c2\"@@@", + "@@@STEP_LOG_LINE@json.output@ \"Angle/\": {@@@", + "@@@STEP_LOG_LINE@json.output@ \"revision\": \"1fd70473fb3de634b409d4acaf49ffc1f90aae1f\"@@@", "@@@STEP_LOG_LINE@json.output@ }, @@@", "@@@STEP_LOG_LINE@json.output@ \"src/blatley/\": {@@@", "@@@STEP_LOG_LINE@json.output@ \"revision\": \"5e800497199d615131a76cd10651e74d7c8a0962\"@@@", @@ -148,7 +148,7 @@ "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient recurse (git config user.name)" + "name": "[spec: Angle] gclient recurse (git config user.name)" }, { "cmd": [ @@ -165,7 +165,7 @@ "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient recurse (git config user.email)" + "name": "[spec: Angle] gclient recurse (git config user.email)" }, { "cmd": [ diff --git a/recipe_modules/gclient/example.expected/revision.json b/recipe_modules/gclient/example.expected/revision.json index 1b1882802..615a7a9a5 100644 --- a/recipe_modules/gclient/example.expected/revision.json +++ b/recipe_modules/gclient/example.expected/revision.json @@ -87,13 +87,13 @@ "RECIPE_PACKAGE_REPO[depot_tools]/gclient.py", "config", "--spec", - "cache_dir = '[GIT_CACHE]'\nsolutions = [{'deps_file': '.DEPS.git', 'managed': True, 'name': 'WebKit', 'safesync_url': 'https://blink-status.appspot.com/lkgr', 'url': 'svn://svn.chromium.org/blink/trunk'}]" + "cache_dir = '[GIT_CACHE]'\nsolutions = [{'deps_file': '.DEPS.git', 'managed': True, 'name': 'Angle', 'url': 'https://chromium.googlesource.com/angle/angle.git'}]" ], "cwd": "[SLAVE_BUILD]/src/third_party", "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient setup" + "name": "[spec: Angle] gclient setup" }, { "cmd": [ @@ -111,7 +111,9 @@ "--no-nag-max", "--delete_unversioned_trees", "--revision", - "third_party/WebKit@123", + "Angle@abc", + "--revision", + "src/third_party/angle@refs/heads/lkgr", "--output-json", "/path/to/tmp/json" ], @@ -119,12 +121,12 @@ "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient sync", + "name": "[spec: Angle] gclient sync", "~followup_annotations": [ "@@@STEP_LOG_LINE@json.output@{@@@", "@@@STEP_LOG_LINE@json.output@ \"solutions\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"WebKit/\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"revision\": \"3eebce6ea96f9e6c03e9252a4f8ef2ea9fe141c2\"@@@", + "@@@STEP_LOG_LINE@json.output@ \"Angle/\": {@@@", + "@@@STEP_LOG_LINE@json.output@ \"revision\": \"1fd70473fb3de634b409d4acaf49ffc1f90aae1f\"@@@", "@@@STEP_LOG_LINE@json.output@ }, @@@", "@@@STEP_LOG_LINE@json.output@ \"src/blatley/\": {@@@", "@@@STEP_LOG_LINE@json.output@ \"revision\": \"5e800497199d615131a76cd10651e74d7c8a0962\"@@@", @@ -150,7 +152,7 @@ "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient recurse (git config user.name)" + "name": "[spec: Angle] gclient recurse (git config user.name)" }, { "cmd": [ @@ -167,7 +169,7 @@ "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient recurse (git config user.email)" + "name": "[spec: Angle] gclient recurse (git config user.email)" }, { "cmd": [ diff --git a/recipe_modules/gclient/example.expected/tryserver.json b/recipe_modules/gclient/example.expected/tryserver.json index 13889c24e..6fb0e9f24 100644 --- a/recipe_modules/gclient/example.expected/tryserver.json +++ b/recipe_modules/gclient/example.expected/tryserver.json @@ -87,13 +87,13 @@ "RECIPE_PACKAGE_REPO[depot_tools]/gclient.py", "config", "--spec", - "cache_dir = '[GIT_CACHE]'\nsolutions = [{'deps_file': '.DEPS.git', 'managed': True, 'name': 'WebKit', 'safesync_url': 'https://blink-status.appspot.com/lkgr', 'url': 'svn://svn.chromium.org/blink/trunk'}]" + "cache_dir = '[GIT_CACHE]'\nsolutions = [{'deps_file': '.DEPS.git', 'managed': True, 'name': 'Angle', 'url': 'https://chromium.googlesource.com/angle/angle.git'}]" ], "cwd": "[SLAVE_BUILD]/src/third_party", "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient setup" + "name": "[spec: Angle] gclient setup" }, { "cmd": [ @@ -111,7 +111,9 @@ "--no-nag-max", "--delete_unversioned_trees", "--revision", - "third_party/WebKit@123", + "Angle@HEAD", + "--revision", + "src/third_party/angle@refs/heads/lkgr", "--output-json", "/path/to/tmp/json" ], @@ -119,12 +121,12 @@ "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient sync", + "name": "[spec: Angle] gclient sync", "~followup_annotations": [ "@@@STEP_LOG_LINE@json.output@{@@@", "@@@STEP_LOG_LINE@json.output@ \"solutions\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"WebKit/\": {@@@", - "@@@STEP_LOG_LINE@json.output@ \"revision\": \"3eebce6ea96f9e6c03e9252a4f8ef2ea9fe141c2\"@@@", + "@@@STEP_LOG_LINE@json.output@ \"Angle/\": {@@@", + "@@@STEP_LOG_LINE@json.output@ \"revision\": \"1fd70473fb3de634b409d4acaf49ffc1f90aae1f\"@@@", "@@@STEP_LOG_LINE@json.output@ }, @@@", "@@@STEP_LOG_LINE@json.output@ \"src/blatley/\": {@@@", "@@@STEP_LOG_LINE@json.output@ \"revision\": \"5e800497199d615131a76cd10651e74d7c8a0962\"@@@", @@ -150,7 +152,7 @@ "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient recurse (git config user.name)" + "name": "[spec: Angle] gclient recurse (git config user.name)" }, { "cmd": [ @@ -167,7 +169,7 @@ "env": { "PATH": "%(PATH)s:RECIPE_PACKAGE_REPO[depot_tools]" }, - "name": "[spec: WebKit] gclient recurse (git config user.email)" + "name": "[spec: Angle] gclient recurse (git config user.email)" }, { "cmd": [ diff --git a/recipe_modules/gclient/example.py b/recipe_modules/gclient/example.py index 7da82ee42..6614c67ef 100644 --- a/recipe_modules/gclient/example.py +++ b/recipe_modules/gclient/example.py @@ -70,15 +70,12 @@ def RunSteps(api): api.gclient.c = src_cfg api.gclient.checkout() - api.gclient.spec_alias = 'WebKit' + api.gclient.spec_alias = 'Angle' bl_cfg = api.gclient.make_config() soln = bl_cfg.solutions.add() - soln.name = 'WebKit' - soln.url = 'svn://svn.chromium.org/blink/trunk' - bl_cfg.revisions['third_party/WebKit'] = '123' - - # Use safesync url for lkgr. - soln.safesync_url = 'https://blink-status.appspot.com/lkgr' + soln.name = 'Angle' + soln.url = 'https://chromium.googlesource.com/angle/angle.git' + bl_cfg.revisions['src/third_party/angle'] = 'refs/heads/lkgr' bl_cfg.got_revision_mapping['src/blatley'] = 'got_blatley_revision' api.gclient.checkout(