Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1299)

Side by Side Diff: Tools/GardeningServer/model/ct-failure-group.html

Issue 498523002: [Sheriff-o-matic] Use likely_revisions instead of first_failing/last_passing (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: sort git hashes Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <!-- 1 <!--
2 Copyright 2014 The Chromium Authors. All rights reserved. 2 Copyright 2014 The Chromium Authors. All rights reserved.
3 Use of this source code is governed by a BSD-style license that can be 3 Use of this source code is governed by a BSD-style license that can be
4 found in the LICENSE file. 4 found in the LICENSE file.
5 --> 5 -->
6 6
7 <link rel="import" href="ct-commit-list.html"> 7 <link rel="import" href="ct-commit-list.html">
8 8
9 <script> 9 <script>
10 function CTFailureGroup(key, failures, annotation) { 10 function CTFailureGroup(key, failures, revisions, annotation) {
11 this.key = key; 11 this.key = key;
12 this.failures = failures; 12 this.failures = failures;
13 this.revisions = revisions.slice() || [];
ojan 2014/08/23 01:23:05 No need for the || here, right?
Mathieu 2014/08/24 23:42:11 Done.
13 this._annotation = annotation || {}; 14 this._annotation = annotation || {};
14 this._computeProperties(); 15 this._computeProperties();
15 } 16 }
16 17
17 CTFailureGroup.prototype.snoozeUntil = function(time) { 18 CTFailureGroup.prototype.snoozeUntil = function(time) {
18 return this._annotate({ 19 return this._annotate({
19 snoozeTime: time, 20 snoozeTime: time,
20 }); 21 });
21 }; 22 };
22 23
23 CTFailureGroup.prototype.unsnooze = function() { 24 CTFailureGroup.prototype.unsnooze = function() {
24 return this._annotate({ 25 return this._annotate({
25 snoozeTime: undefined, 26 snoozeTime: undefined,
26 }); 27 });
27 }; 28 };
28 29
29 CTFailureGroup.prototype.commitList = function(commits) { 30 CTFailureGroup.prototype.commitList = function(commits) {
30 return new CTCommitList(this, commits); 31 return new CTCommitList(commits, this.revisions);
31 }; 32 };
32 33
33 CTFailureGroup.prototype.setBug = function(bug) { 34 CTFailureGroup.prototype.setBug = function(bug) {
34 if (/^[0-9]+$/.test(bug)) 35 if (/^[0-9]+$/.test(bug))
35 bug = 'http://crbug.com/' + bug; 36 bug = 'http://crbug.com/' + bug;
36 return this._annotate({ 37 return this._annotate({
37 bug: bug, 38 bug: bug,
38 }); 39 });
39 }; 40 };
40 41
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 }.bind(this)); 87 }.bind(this));
87 }; 88 };
88 89
89 CTFailureGroup.fetchAnnotations = function() { 90 CTFailureGroup.fetchAnnotations = function() {
90 // FIXME: Fetch annotations from frontend. 91 // FIXME: Fetch annotations from frontend.
91 var stored = localStorage.CTFailureGroupAnnotations; 92 var stored = localStorage.CTFailureGroupAnnotations;
92 var annotations = stored ? JSON.parse(stored) : {}; 93 var annotations = stored ? JSON.parse(stored) : {};
93 return Promise.resolve(annotations); 94 return Promise.resolve(annotations);
94 }; 95 };
95 </script> 96 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698