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

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

Issue 707123002: history: announce search/time ranges. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: test fix Created 6 years, 1 month 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
« no previous file with comments | « chrome/browser/ui/webui/history_ui.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 GEN('#include "chrome/test/data/webui/history_ui_browsertest.h"'); 5 GEN('#include "chrome/test/data/webui/history_ui_browsertest.h"');
6 6
7 /** @const */ var TOTAL_RESULT_COUNT = 160; 7 /** @const */ var TOTAL_RESULT_COUNT = 160;
8 /** @const */ var WAIT_TIMEOUT = 200; 8 /** @const */ var WAIT_TIMEOUT = 200;
9 9
10 /** 10 /**
(...skipping 725 matching lines...) Expand 10 before | Expand all | Expand 10 after
736 }); 736 });
737 737
738 TEST_F('RangeHistoryWebUITest', 'monthViewEmptyMonth', function() { 738 TEST_F('RangeHistoryWebUITest', 'monthViewEmptyMonth', function() {
739 // Change to monthly view. 739 // Change to monthly view.
740 setPageState('', 0, HistoryModel.Range.MONTH, 2); 740 setPageState('', 0, HistoryModel.Range.MONTH, 2);
741 741
742 waitForCallback('historyResult', function() { 742 waitForCallback('historyResult', function() {
743 // See if the correct number of days is shown. 743 // See if the correct number of days is shown.
744 var resultsDisplay = $('results-display'); 744 var resultsDisplay = $('results-display');
745 assertEquals(0, resultsDisplay.querySelectorAll('.months-results').length); 745 assertEquals(0, resultsDisplay.querySelectorAll('.months-results').length);
746 assertEquals(1, resultsDisplay.querySelectorAll('div').length); 746 var noResults = loadTimeData.getString('noResults');
747 assertNotEquals(-1, $('results-header').textContent.indexOf(noResults));
747 748
748 testDone(); 749 testDone();
749 }); 750 });
750 }); 751 });
751 752
752 /** 753 /**
753 * Fixture for History WebUI tests using the real history backend. 754 * Fixture for History WebUI tests using the real history backend.
754 * @extends {BaseHistoryWebUITest} 755 * @extends {BaseHistoryWebUITest}
755 * @constructor 756 * @constructor
756 */ 757 */
(...skipping 351 matching lines...) Expand 10 before | Expand all | Expand 10 after
1108 TEST_F('HistoryWebUIWithSchemesTest', 'groupingWithSchemes', function() { 1109 TEST_F('HistoryWebUIWithSchemesTest', 'groupingWithSchemes', function() {
1109 // Switch to the week view. 1110 // Switch to the week view.
1110 $('timeframe-controls').querySelectorAll('input')[1].click(); 1111 $('timeframe-controls').querySelectorAll('input')[1].click();
1111 waitForCallback('historyResult', function() { 1112 waitForCallback('historyResult', function() {
1112 // Each URL should be organized under a different "domain". 1113 // Each URL should be organized under a different "domain".
1113 expectEquals(document.querySelectorAll('.entry').length, 4); 1114 expectEquals(document.querySelectorAll('.entry').length, 4);
1114 expectEquals(document.querySelectorAll('.site-domain-wrapper').length, 4); 1115 expectEquals(document.querySelectorAll('.site-domain-wrapper').length, 4);
1115 testDone(); 1116 testDone();
1116 }); 1117 });
1117 }); 1118 });
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/history_ui.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698