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

Unified Diff: chrome/test/data/webui/icon_test.html

Issue 1919183005: Cleanup: Extract icon related methods outside of util.js (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rename favicon.html to icon.html Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/test/data/webui/icon_test.html
diff --git a/chrome/test/data/webui/util_test.html b/chrome/test/data/webui/icon_test.html
similarity index 67%
copy from chrome/test/data/webui/util_test.html
copy to chrome/test/data/webui/icon_test.html
index 6fdb55127b703430e23ef35c59d6d1fbdf7e2b68..a01fd760b1782f2c3e1e583bc5fe6e4b586eec78 100644
--- a/chrome/test/data/webui/util_test.html
+++ b/chrome/test/data/webui/icon_test.html
@@ -3,23 +3,6 @@
<body>
<script>
-function testQuoteString() {
- // Basic cases.
- assertEquals('\"test\"', quoteString('"test"'));
- assertEquals('\\!\\?', quoteString('!?'));
- assertEquals('\\(\\._\\.\\) \\( \\:l \\) \\(\\.-\\.\\)',
- quoteString('(._.) ( :l ) (.-.)'));
-
- // Using the output as a regex.
- var re = new RegExp(quoteString('"hello"'), 'gim');
- var match = re.exec('She said "Hello" loudly');
- assertEquals(9, match.index);
-
- re = new RegExp(quoteString('Hello, .*'), 'gim');
- match = re.exec('Hello, world');
- assertEquals(null, match);
-}
-
// Test the case where a non-favicon URL is passed.
function testGetFaviconImageSet_NonFavicon() {
var url = 'http://foo.com';
@@ -32,7 +15,7 @@ function testGetFaviconImageSet_NonFavicon() {
var isDesktop = cr.isMac || cr.isChromeOS || cr.isWindows || cr.isLinux;
var expected = isDesktop ? expectedDesktop : expectedOther;
- assertEquals(expected, getFaviconImageSet(url));
+ assertEquals(expected, cr.icon.getFaviconImageSet(url));
}
// Test the case where the favicon URL is passed.
@@ -47,7 +30,7 @@ function testGetFaviconImageSet_IconUrl() {
var isDesktop = cr.isMac || cr.isChromeOS || cr.isWindows || cr.isLinux;
var expected = isDesktop ? expectedDesktop : expectedOther;
- assertEquals(expected, getFaviconImageSet(url));
+ assertEquals(expected, cr.icon.getFaviconImageSet(url));
}
</script>

Powered by Google App Engine
This is Rietveld 408576698