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

Unified Diff: chrome/test/data/extensions/api_test/executescript/basic/test.html

Issue 7517001: Switch from WebDocument::insertStyleText to ::insertUserStyleSheet for programatic CSS injection. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebaseline Created 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/renderer/extensions/user_script_idle_scheduler.cc ('k') | content/common/view_messages.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/extensions/api_test/executescript/basic/test.html
diff --git a/chrome/test/data/extensions/api_test/executescript/basic/test.html b/chrome/test/data/extensions/api_test/executescript/basic/test.html
index a5a2f668fc7f80e186d4829eee894752177b6efe..391c43a6482a0f8e6ef1d64b5aa50daba9c3677c 100644
--- a/chrome/test/data/extensions/api_test/executescript/basic/test.html
+++ b/chrome/test/data/extensions/api_test/executescript/basic/test.html
@@ -72,6 +72,19 @@ chrome.test.getConfig(function(config) {
});
},
+ function insertCSSTextShouldNotAffectDOM() {
+ chrome.tabs.insertCSS(tabId, {code: 'p {display: none}'}, function() {
+ chrome.tabs.executeScript(
+ tabId,
+ {code: 'document.title = document.styleSheets.length'},
+ function() {
+ chrome.tabs.get(tabId, pass(function(tab) {
+ assertEq(tab.title, '0');
+ }));
+ });
+ });
+ },
+
function executeJavaScriptCodeShouldFail() {
chrome.tabs.update(tabId, { url: testFailureUrl }, function() {
var script_file = {};
« no previous file with comments | « chrome/renderer/extensions/user_script_idle_scheduler.cc ('k') | content/common/view_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698