зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1461042 [wpt PR 10971] - Add git revision to run_info (and wptreport), a=testonly
Automatic update from web-platform-testsAdd git revision to run_info (and wptreport) (#10971) -- wpt-commits: 15f9e082e6a532cb06c5f666ee3b7833fadf2500 wpt-pr: 10971
This commit is contained in:
Родитель
25000d173f
Коммит
70eaa7c581
|
@ -1,4 +1,5 @@
|
|||
import os
|
||||
import subprocess
|
||||
from collections import defaultdict
|
||||
|
||||
from wptmanifest.parser import atoms
|
||||
|
@ -67,9 +68,18 @@ def get_run_info(metadata_root, product, **kwargs):
|
|||
class RunInfo(dict):
|
||||
def __init__(self, metadata_root, product, debug, browser_version=None, extras=None):
|
||||
import mozinfo
|
||||
|
||||
self._update_mozinfo(metadata_root)
|
||||
self.update(mozinfo.info)
|
||||
|
||||
from update.tree import GitTree
|
||||
try:
|
||||
# GitTree.__init__ throws if we are not in a git tree.
|
||||
rev = GitTree().rev
|
||||
except subprocess.CalledProcessError:
|
||||
rev = None
|
||||
if rev:
|
||||
self["revision"] = rev
|
||||
|
||||
self["product"] = product
|
||||
if debug is not None:
|
||||
self["debug"] = debug
|
||||
|
|
Загрузка…
Ссылка в новой задаче