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

Unified Diff: chrome/test/data/extensions/platform_apps/web_view_src_attribute/main.js

Issue 11233065: Rename <browser> shim to <webview> (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merged with ToT. No longer exposed to Extensions Created 8 years, 2 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/extensions/platform_apps/web_view_src_attribute/main.js
diff --git a/chrome/test/data/extensions/platform_apps/browser_tag_src_attribute/main.js b/chrome/test/data/extensions/platform_apps/web_view_src_attribute/main.js
similarity index 73%
rename from chrome/test/data/extensions/platform_apps/browser_tag_src_attribute/main.js
rename to chrome/test/data/extensions/platform_apps/web_view_src_attribute/main.js
index 91325bcdc9505f437ac6b14ce676c7586ce92a12..66984297e13e819fc756c792de5f9bb84e428299 100644
--- a/chrome/test/data/extensions/platform_apps/browser_tag_src_attribute/main.js
+++ b/chrome/test/data/extensions/platform_apps/web_view_src_attribute/main.js
@@ -10,50 +10,50 @@ var checkSrc = function(element, expectedValue) {
onload = function() {
chrome.test.runTests([
- function browserTag() {
+ function webview() {
var expectedSrcOne = 'data:text/html,<body>One</body>';
var expectedSrcTwo = 'data:text/html,<body>Two</body>';
var expectedSrcThree = 'data:text/html,<body>Three</body>';
var step = 1;
- // For setting src, we check if both browserTag.setAttribute('src', ?);
- // and browserTag.src = ?; works propertly.
- var browserTag = document.querySelector('browser');
+ // For setting src, we check if both webview.setAttribute('src', ?);
+ // and webview.src = ?; works propertly.
+ var webview = document.querySelector('webview');
var runStep2 = function() {
step = 2;
chrome.test.log('run step: ' + step);
// Check if initial src is set correctly.
- checkSrc(browserTag, expectedSrcOne);
- browserTag.setAttribute('src', expectedSrcTwo);
+ checkSrc(webview, expectedSrcOne);
+ webview.setAttribute('src', expectedSrcTwo);
};
var runStep3 = function() {
step = 3;
chrome.test.log('run step: ' + step);
// Expect the src change to be reflected.
- checkSrc(browserTag, expectedSrcTwo);
+ checkSrc(webview, expectedSrcTwo);
// Set src attribute directly on the element.
- browserTag.src = expectedSrcThree;
+ webview.src = expectedSrcThree;
};
var runStep4 = function() {
step = 4;
chrome.test.log('run step: ' + step);
// Expect the src change to be reflected.
- checkSrc(browserTag, expectedSrcThree);
+ checkSrc(webview, expectedSrcThree);
// Set empty src, this will be ignored.
- browserTag.setAttribute('src', '');
+ webview.setAttribute('src', '');
setTimeout(function() {
// Expect empty src to be ignored.
- checkSrc(browserTag, expectedSrcThree);
+ checkSrc(webview, expectedSrcThree);
// Set empty src again, directly changing the src attribute.
- browserTag.src = '';
+ webview.src = '';
setTimeout(function() {
// Expect empty src to be ignored.
- checkSrc(browserTag, expectedSrcThree);
+ checkSrc(webview, expectedSrcThree);
chrome.test.succeed();
}, 0);
}, 0);
@@ -61,7 +61,7 @@ onload = function() {
// Wait for navigation to complete before checking src attribute.
- browserTag.addEventListener('loadcommit', function(e) {
+ webview.addEventListener('loadcommit', function(e) {
switch (step) {
case 1:
runStep2();

Powered by Google App Engine
This is Rietveld 408576698