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

Side by Side Diff: chrome/test/data/webui/i18n_process_css_test.html

Issue 1246253002: Convert i18n_process.css to use /deep/ instead of ::shadow and add tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: thestig@ review Created 5 years, 5 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 unified diff | Download patch
« no previous file with comments | « chrome/test/data/BUILD.gn ('k') | chrome/test/data/webui/webui_resource_browsertest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!doctype html>
2 <style>
3 <include src="../../../../ui/webui/resources/css/i18n_process.css">
4 </style>
5 <h1 i18n-content="buy"></h1>
6 <span i18n-values=".innerHTML:link"></span>
7 <script>
8
9 function testI18nProcess_NbspPlaceholder() {
10 var h1 = document.querySelector('h1');
11 var span = document.querySelector('span');
12
13 assertFalse(document.documentElement.hasAttribute('i18n-processed'));
14 assertEquals('', h1.textContent);
15 assertEquals('', span.textContent);
16
17 /* We can't check that the non-breaking space hack actually works because it
18 * uses :psuedo-elements that are inaccessible to the DOM. Let's just check
19 * that they're not auto-collapsed. */
20 assertNotEqual(0, h1.offsetHeight);
21 assertNotEqual(0, span.offsetHeight);
22
23 h1.removeAttribute('i18n-content');
24 assertEquals(0, h1.offsetHeight);
25
26 span.removeAttribute('i18n-values');
27 assertEquals(0, span.offsetHeight);
28 }
29
30 </script>
OLDNEW
« no previous file with comments | « chrome/test/data/BUILD.gn ('k') | chrome/test/data/webui/webui_resource_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698