Commit 0ba1c23c authored by Michael Achenbach's avatar Michael Achenbach Committed by Commit Bot

[release] Replace raw DEPS processing with gclient getdep

No-Try: true
Bug: chromium:1106435
Change-Id: I120d3930e4e8be7010d8d1f1928829ca0882638d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2304578Reviewed-by: 's avatarTamer Tas <tmrts@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#68913}
parent b7430e99
......@@ -46,14 +46,10 @@ class DetectLastRoll(Step):
self['json_output']['monitoring_state'] = 'detect_last_roll'
self["last_roll"] = self._options.last_roll
if not self["last_roll"]:
# Interpret the DEPS file to retrieve the v8 revision.
# TODO(machenbach): This should be part or the setdep api of
# depot_tools.
Var = lambda var: '%s'
exec(FileToText(os.path.join(self._options.chromium, "DEPS")))
# The revision rolled last.
self["last_roll"] = vars['v8_revision']
# Get last-rolled v8 revision from Chromium's DEPS file.
self["last_roll"] = self.Command(
"gclient", "getdep -r src/v8", cwd=self._options.chromium).strip()
self["last_version"] = self.GetVersionTag(self["last_roll"])
assert self["last_version"], "The last rolled v8 revision is not tagged."
......
......@@ -558,9 +558,11 @@ deps = {
TEST_CONFIG["CHROMIUM"] = self.MakeEmptyTempDirectory()
json_output_file = os.path.join(TEST_CONFIG["CHROMIUM"], "out.json")
TextToFile(self.FAKE_DEPS, os.path.join(TEST_CONFIG["CHROMIUM"], "DEPS"))
chrome_dir = TEST_CONFIG["CHROMIUM"]
self.Expect([
Cmd("git fetch origin", ""),
Cmd("git fetch origin +refs/tags/*:refs/tags/*", ""),
Cmd("gclient getdep -r src/v8", "last_roll_hsh", cwd=chrome_dir),
Cmd("git describe --tags last_roll_hsh", "3.22.4"),
Cmd("git fetch origin +refs/tags/*:refs/tags/*", ""),
Cmd("git rev-list --max-age=395200 --tags",
......@@ -597,6 +599,7 @@ deps = {
expectations = [
Cmd("git fetch origin", ""),
Cmd("git fetch origin +refs/tags/*:refs/tags/*", ""),
Cmd("gclient getdep -r src/v8", "last_roll_hsh", cwd=chrome_dir),
Cmd("git describe --tags last_roll_hsh", "3.22.3.1"),
Cmd("git fetch origin +refs/tags/*:refs/tags/*", ""),
Cmd("git rev-list --max-age=395200 --tags",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment