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

Side by Side Diff: Tools/GardeningServer/scripts/model.js

Issue 355193005: Remove checkout functionality from GOM (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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
« no previous file with comments | « Tools/GardeningServer/scripts/controllers.js ('k') | Tools/GardeningServer/scripts/ui.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 13 matching lines...) Expand all
24 */ 24 */
25 25
26 var model = model || {}; 26 var model = model || {};
27 27
28 (function () { 28 (function () {
29 29
30 var kCommitLogLength = 50; 30 var kCommitLogLength = 50;
31 31
32 model.state = {}; 32 model.state = {};
33 model.state.failureAnalysisByTest = {}; 33 model.state.failureAnalysisByTest = {};
34 model.state.expectationsUpdateQueue = [];
35 34
36 function findAndMarkRevertedRevisions(commitDataList) 35 function findAndMarkRevertedRevisions(commitDataList)
37 { 36 {
38 var revertedRevisions = {}; 37 var revertedRevisions = {};
39 $.each(commitDataList, function(index, commitData) { 38 $.each(commitDataList, function(index, commitData) {
40 if (commitData.revertedRevision) 39 if (commitData.revertedRevision)
41 revertedRevisions[commitData.revertedRevision] = true; 40 revertedRevisions[commitData.revertedRevision] = true;
42 }); 41 });
43 $.each(commitDataList, function(index, commitData) { 42 $.each(commitDataList, function(index, commitData) {
44 if (commitData.revision in revertedRevisions) 43 if (commitData.revision in revertedRevisions)
(...skipping 20 matching lines...) Expand all
65 if (commitData.revision != revision) 64 if (commitData.revision != revision)
66 continue; 65 continue;
67 if (fuzzyFind(failureAnalysis.testName, commitData)) { 66 if (fuzzyFind(failureAnalysis.testName, commitData)) {
68 failureAnalysis.oldestFailingRevision = revision; 67 failureAnalysis.oldestFailingRevision = revision;
69 failureAnalysis.newestPassingRevision = revision - 1; 68 failureAnalysis.newestPassingRevision = revision - 1;
70 return; 69 return;
71 } 70 }
72 } 71 }
73 } 72 }
74 73
75 model.queueForExpectationUpdate = function(failureInfo)
76 {
77 model.state.expectationsUpdateQueue.push(failureInfo);
78 };
79
80 model.takeExpectationUpdateQueue = function()
81 {
82 var queue = model.state.expectationsUpdateQueue;
83 model.state.expectationsUpdateQueue = [];
84 return queue;
85 };
86
87 var g_commitIndex = {}; 74 var g_commitIndex = {};
88 75
89 model.updateRecentCommits = function() 76 model.updateRecentCommits = function()
90 { 77 {
91 return trac.recentCommitData('trunk', kCommitLogLength).then(function(commit DataList) { 78 return trac.recentCommitData('trunk', kCommitLogLength).then(function(commit DataList) {
92 model.state.recentCommits = commitDataList; 79 model.state.recentCommits = commitDataList;
93 updateCommitIndex(); 80 updateCommitIndex();
94 findAndMarkRevertedRevisions(model.state.recentCommits); 81 findAndMarkRevertedRevisions(model.state.recentCommits);
95 }); 82 });
96 }; 83 };
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
219 }; 206 };
220 207
221 // FIXME: Consider looking at the history to see how long this test 208 // FIXME: Consider looking at the history to see how long this test
222 // has been failing. 209 // has been failing.
223 210
224 failureCallback(failureAnalysis); 211 failureCallback(failureAnalysis);
225 }); 212 });
226 }; 213 };
227 214
228 })(); 215 })();
OLDNEW
« no previous file with comments | « Tools/GardeningServer/scripts/controllers.js ('k') | Tools/GardeningServer/scripts/ui.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698