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

Side by Side Diff: chrome/test/data/webui/ntp4.js

Issue 8689013: Remove TOUCH_UI specific new tab page. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge with trunk Created 9 years 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 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * TestFixture for NTP4 WebUI testing. 6 * TestFixture for NTP4 WebUI testing.
7 * @extends {testing.Test} 7 * @extends {testing.Test}
8 * @constructor 8 * @constructor
9 */ 9 */
10 function NTP4WebUITest() {} 10 function NTP4WebUITest() {}
11 11
12 NTP4WebUITest.prototype = { 12 NTP4WebUITest.prototype = {
13 __proto__: testing.Test.prototype, 13 __proto__: testing.Test.prototype,
14 14
15 /** 15 /**
16 * Browse to the newtab page & call preLoad(). 16 * Browse to the newtab page & call preLoad().
17 */ 17 */
18 browsePreload: 'chrome://newtab', 18 browsePreload: 'chrome://newtab',
19 }; 19 };
20 20
21 // TODO(danakj): Fix this test to work with the TOUCH_UI version of NTP.
22 // http://crbug.com/99895
23 GEN('#if defined(TOUCH_UI)');
24 GEN('#define MAYBE_TestBrowsePages DISABLED_TestBrowsePages');
25 GEN('#else');
26 GEN('#define MAYBE_TestBrowsePages TestBrowsePages');
27 GEN('#endif');
28
29 // Test loading new tab page and selecting each card doesn't have console 21 // Test loading new tab page and selecting each card doesn't have console
30 // errors. 22 // errors.
31 TEST_F('NTP4WebUITest', 'MAYBE_TestBrowsePages', function() { 23 TEST_F('NTP4WebUITest', 'TestBrowsePages', function() {
32 // This tests the ntp4 new tab page which is not used on touch builds. 24 // This tests the ntp4 new tab page which is not used on touch builds.
33 var cardSlider = ntp4.getCardSlider(); 25 var cardSlider = ntp4.getCardSlider();
34 assertNotEquals(null, cardSlider); 26 assertNotEquals(null, cardSlider);
35 for (var i = 0; i < cardSlider.cardCount; ++i) { 27 for (var i = 0; i < cardSlider.cardCount; ++i) {
36 cardSlider.selectCard(i); 28 cardSlider.selectCard(i);
37 expectEquals(i, cardSlider.currentCard); 29 expectEquals(i, cardSlider.currentCard);
38 } 30 }
39 }); 31 });
OLDNEW
« chrome/browser/ui/webui/ntp/new_tab_ui.cc ('K') | « chrome/common/chrome_switches.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698