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

Side by Side Diff: Tools/GardeningServer/ui/ct-embedded-flakiness-dashboard-tests.html

Issue 416673003: Show non-webkit test failures in the failure stream (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: add files accidentally left out 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
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-embedded-flakiness-dashboard.html"> 7 <link rel="import" href="ct-embedded-flakiness-dashboard.html">
8 8
9 <script> 9 <script>
10 (function() { 10 (function() {
11 11
12 module("ct-embedded-flakiness-dashboard"); 12 module("ct-embedded-flakiness-dashboard");
13 13
14 asyncTest("url", 1, function() { 14 asyncTest("url", 1, function() {
15 var oldUrlForEmbeddedFlakinessDashboard = ui.urlForEmbeddedFlakinessDashboard; 15 var oldUrlForEmbeddedFlakinessDashboard = ui.urlForEmbeddedFlakinessDashboard;
16 var reset = function() { 16 var reset = function() {
17 ui.urlForEmbeddedFlakinessDashboard = oldUrlForEmbeddedFlakinessDashboard; 17 ui.urlForEmbeddedFlakinessDashboard = oldUrlForEmbeddedFlakinessDashboard;
18 } 18 }
19 19
20 try { 20 try {
21 ui.urlForEmbeddedFlakinessDashboard = function(testList) { return "about:bla nk#" + testList.join(','); } 21 ui.urlForEmbeddedFlakinessDashboard = function(test, step) { return "about:b lank#" + test + step; }
22 var embeddedFlakinessDashboard = document.createElement('ct-embedded-flakine ss-dashboard'); 22 var embeddedFlakinessDashboard = document.createElement('ct-embedded-flakine ss-dashboard');
23 var testName = "foo/bar.html"; 23 var testName = "foo/bar.html";
24 embeddedFlakinessDashboard.test = testName; 24 var step = "foo_tests";
25 embeddedFlakinessDashboard.test = {
26 testName: testName,
27 step: step,
28 };
25 29
26 requestAnimationFrame(function() { 30 requestAnimationFrame(function() {
27 var iframe = embeddedFlakinessDashboard.shadowRoot.querySelector('#iframe' ); 31 var iframe = embeddedFlakinessDashboard.shadowRoot.querySelector('#iframe' );
28 equal(iframe.src, ui.urlForEmbeddedFlakinessDashboard([testName])); 32 equal(iframe.src, ui.urlForEmbeddedFlakinessDashboard(testName, step));
29 reset(); 33 reset();
30 start(); 34 start();
31 }); 35 });
32 } catch (e) { 36 } catch (e) {
33 reset(); 37 reset();
34 } 38 }
35 }); 39 });
36 40
37 asyncTest("heightChanged", 1, function() { 41 asyncTest("heightChanged", 1, function() {
38 var embeddedFlakinessDashboard = document.createElement('ct-embedded-flakiness -dashboard'); 42 var embeddedFlakinessDashboard = document.createElement('ct-embedded-flakiness -dashboard');
39 43
40 function finishTest() { 44 function finishTest() {
41 window.removeEventListener('message', finishTest); 45 window.removeEventListener('message', finishTest);
42 var iframe = embeddedFlakinessDashboard.shadowRoot.querySelector('#iframe'); 46 var iframe = embeddedFlakinessDashboard.shadowRoot.querySelector('#iframe');
43 equal(iframe.style.height, "100px"); 47 equal(iframe.style.height, "100px");
44 start(); 48 start();
45 } 49 }
46 window.addEventListener('message', finishTest); 50 window.addEventListener('message', finishTest);
47 51
48 requestAnimationFrame(function() { 52 requestAnimationFrame(function() {
49 window.postMessage({command: 'heightChanged', height: "100"}, '*'); 53 window.postMessage({command: 'heightChanged', height: "100"}, '*');
50 }); 54 });
51 }); 55 });
52 56
53 })() 57 })()
54 </script> 58 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698