Skip to content

Commit

Permalink
Replace stale Version field with revision
Browse files Browse the repository at this point in the history
  • Loading branch information
krzyzacy committed Dec 20, 2018
1 parent 46fcefb commit d1474ea
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion gubernator/main_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def init_build(build_dir, started=True, finished=True,
"""Create faked files for a build."""
start_json = {'timestamp': 1406535800}
finish_json = {'passed': True, 'result': 'SUCCESS', 'timestamp': 1406536800}
(finish_json if finished_has_version else start_json)['version'] = 'v1+56'
(finish_json if finished_has_version else start_json)['revision'] = 'v1+56'
if started:
write(build_dir + 'started.json', start_json)
if finished:
Expand Down
2 changes: 1 addition & 1 deletion gubernator/templates/build.html
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ <h1>{% if pr and pr != "batch" %}<a href="/pr/{{pr_path}}{{pr}}">{% if repo !=
% endif
<tr><td>Started<td>{{started['timestamp']|timestamp}}
{% if finished %}<tr><td>Elapsed<td>{{(finished['timestamp']-started['timestamp'])|duration}}{% endif %}
<tr><td>Version<td><a href="https://github.com/{{repo}}/commit/{{commit}}">{{started['version'] or finished['version']}}</a>
<tr><td>Revision<td><a href="https://github.com/{{repo}}/commit/{{commit}}">{{started['revision'] or finished['revision']}}</a>
% if 'node' in started
<tr><td>Builder<td>{{started['node']}}
% endif
Expand Down
2 changes: 1 addition & 1 deletion gubernator/view_build_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ def test_build_no_failures(self):
def test_show_metadata(self):
write(self.BUILD_DIR + 'started.json',
{
'version': 'v1+56',
'revision': 'v1+56',
'timestamp': 1406535800,
'node': 'agent-light-7',
'pull': 'master:1234,35:abcd,72814',
Expand Down

0 comments on commit d1474ea

Please sign in to comment.