Index: chrome/test/data/webui/md_history/history_item_test.js |
diff --git a/chrome/test/data/webui/md_history/history_item_test.js b/chrome/test/data/webui/md_history/history_item_test.js |
index 77700e3cb3ca3809dded16d970ad1fa47a02b1df..9ab28b9d823af8bfa739b9f6f0c4f8a84b1c5e66 100644 |
--- a/chrome/test/data/webui/md_history/history_item_test.js |
+++ b/chrome/test/data/webui/md_history/history_item_test.js |
@@ -76,6 +76,16 @@ cr.define('md_history.history_item_test', function() { |
}); |
}); |
+ test('long titles are trimmed', function() { |
+ var item = document.createElement('history-item'); |
+ var longtitle = '0123456789'.repeat(100); |
+ item.item = |
+ createHistoryEntry('2016-06-30', 'http://example.com/' + longtitle); |
+ |
+ var label = item.$$('history-searched-label'); |
+ assertEquals(TITLE_MAX_LENGTH, label.title.length); |
+ }); |
+ |
teardown(function() { |
element.historyData_ = []; |
element.searchedTerm = ''; |