Chromium Code Reviews| OLD | NEW |
|---|---|
| 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="../model/ct-failure.html"> | |
| 7 <link rel="import" href="ct-test-list.html"> | 8 <link rel="import" href="ct-test-list.html"> |
| 8 | 9 |
| 9 <script> | 10 <script> |
| 10 (function () { | 11 (function () { |
| 11 | 12 |
| 12 var kExampleTests = [ | 13 var kExampleTests = [ |
| 13 { | 14 new CTFailure("foo_step", "plugins/gesture-events-scrolled.html", {}, 177164, 177165); |
| 14 "testName": "plugins/gesture-events-scrolled.html", | 15 new CTFailure("foo_step", "plugins/transformed-events.html", {}, 177164, 17716 5); |
| 15 "step": "foo_step", | 16 new CTFailure("foo_step", "plugins/gesture-events.html", {}, 177164, 177165); |
| 16 "resultNodesByBuilder": { | 17 ]; |
| 17 "WebKit Mac10.6 (dbg)": { | 18 |
| 18 "actual": "IMAGE", | 19 var kExampleTestsChromium = [ |
| 19 }, | 20 new CTFailure("browser_tests", "SomeTest.SubTest1", {}, 177164, 177165); |
| 20 }, | 21 new CTFailure("browser_tests", "SomeTest.SubTest2", {}, 177164, 177165); |
| 21 "oldestFailingRevision": 177164, | 22 ]; |
| 22 "newestPassingRevision": 177165, | 23 |
| 23 }, | 24 var kExampleTestsBlink = [ |
| 24 { | 25 new CTFailure("webkit_tests", "fast/events/foo.html", {}, 177164, 177165); |
| 25 "testName": "plugins/transformed-events.html", | 26 new CTFailure("webkit_tests", "fast/events/bar.html", {}, 177164, 177165); |
| 26 "step": "foo_step", | |
| 27 "resultNodesByBuilder": { | |
| 28 "WebKit Mac10.6 (dbg)": { | |
| 29 "actual": "IMAGE", | |
| 30 }, | |
| 31 }, | |
| 32 "oldestFailingRevision": 177164, | |
| 33 "newestPassingRevision": 177165, | |
| 34 }, | |
| 35 { | |
| 36 "testName": "plugins/gesture-events.html", | |
| 37 "step": "foo_step", | |
| 38 "resultNodesByBuilder": { | |
| 39 "WebKit Mac10.6 (dbg)": { | |
| 40 "actual": "IMAGE", | |
| 41 }, | |
| 42 }, | |
| 43 "oldestFailingRevision": 177164, | |
| 44 "newestPassingRevision": 177165, | |
| 45 }, | |
| 46 ]; | 27 ]; |
| 47 | 28 |
| 48 module("ct-test-list"); | 29 module("ct-test-list"); |
| 49 | 30 |
| 50 asyncTest("basic", 4, function() { | 31 asyncTest("basic", 4, function() { |
| 51 var list = document.createElement('ct-test-list'); | 32 var list = document.createElement('ct-test-list'); |
| 52 | 33 |
| 53 list.tests = kExampleTests; | 34 list.tests = kExampleTests; |
| 54 list.tree = 'blink'; | 35 list.tree = 'blink'; |
| 55 | 36 |
| 56 Platform.endOfMicrotask(function() { | 37 Platform.endOfMicrotask(function() { |
| 57 var tests = list.shadowRoot.querySelectorAll('a'); | 38 var tests = list.shadowRoot.querySelectorAll('a'); |
| 58 equal(tests.length, 3); | 39 equal(tests.length, 3); |
| 59 equal(tests[0].href, 'http://test-results.appspot.com/dashboards/flakiness_d ashboard.html#group=@ToT%20Blink&tests=plugins%2Fgesture-events-scrolled.html&te stType=foo_step'); | 40 equal(tests[0].href, 'http://test-results.appspot.com/dashboards/flakiness_d ashboard.html#group=@ToT%20Blink&tests=plugins%2Fgesture-events-scrolled.html&te stType=foo_step'); |
| 60 equal(tests[1].href, 'http://test-results.appspot.com/dashboards/flakiness_d ashboard.html#group=@ToT%20Blink&tests=plugins%2Ftransformed-events.html&testTyp e=foo_step'); | 41 equal(tests[1].href, 'http://test-results.appspot.com/dashboards/flakiness_d ashboard.html#group=@ToT%20Blink&tests=plugins%2Ftransformed-events.html&testTyp e=foo_step'); |
| 61 equal(tests[2].href, 'http://test-results.appspot.com/dashboards/flakiness_d ashboard.html#group=@ToT%20Blink&tests=plugins%2Fgesture-events.html&testType=fo o_step'); | 42 equal(tests[2].href, 'http://test-results.appspot.com/dashboards/flakiness_d ashboard.html#group=@ToT%20Blink&tests=plugins%2Fgesture-events.html&testType=fo o_step'); |
| 62 | 43 |
| 63 start(); | 44 start(); |
| 64 }); | 45 }); |
| 65 }); | 46 }); |
| 66 | 47 |
| 48 asyncTest("groupingChromium", 2, function() { | |
| 49 var list = document.createElement('ct-test-list'); | |
| 50 | |
| 51 list.tests = kExampleTestsChromium; | |
| 52 list.tree = 'chromium'; | |
| 53 | |
| 54 Platform.endOfMicrotask(function() { | |
|
ojan
2014/08/11 19:41:05
endOfMicrotask is a weird broken API. It basically
jochen (gone - plz use gerrit)
2014/08/12 11:55:51
done
| |
| 55 var tests = list.shadowRoot.querySelectorAll('a'); | |
| 56 equal(tests.length, 0); | |
| 57 var icons = list.shadowRoot.querySelectorAll('paper-icon-button'); | |
| 58 equal(icons.length, 1); | |
| 59 | |
| 60 start(); | |
| 61 }); | |
| 62 }); | |
| 63 | |
| 64 asyncTest("groupingBlink", 2, function() { | |
| 65 var list = document.createElement('ct-test-list'); | |
| 66 | |
| 67 list.tests = kExampleTestsBlink; | |
| 68 list.tree = 'blink'; | |
| 69 | |
| 70 Platform.endOfMicrotask(function() { | |
| 71 var tests = list.shadowRoot.querySelectorAll('a'); | |
| 72 equal(tests.length, 0); | |
| 73 var icons = list.shadowRoot.querySelectorAll('paper-icon-button'); | |
| 74 equal(icons.length, 1); | |
| 75 | |
| 76 start(); | |
| 77 }); | |
| 78 }); | |
| 79 | |
| 67 })() | 80 })() |
| 68 </script> | 81 </script> |
| OLD | NEW |