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

Unified Diff: chrome/test/data/extensions/api_test/content_scripts/duplicate_script_injection/should_run_once.js

Issue 2213603002: Prevent duplicate content script injection defined in manifest.json (reland) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed patch 8 code review comments Created 4 years, 3 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/api_test/content_scripts/duplicate_script_injection/should_run_once.js
diff --git a/blimp/common/proto/common.proto b/chrome/test/data/extensions/api_test/content_scripts/duplicate_script_injection/should_run_once.js
similarity index 50%
copy from blimp/common/proto/common.proto
copy to chrome/test/data/extensions/api_test/content_scripts/duplicate_script_injection/should_run_once.js
index 2684302d65efa3c23ef949c266c2ec6081f20e77..081cb22bdb964bccc2b5a47c056721faa48b4e36 100644
--- a/blimp/common/proto/common.proto
+++ b/chrome/test/data/extensions/api_test/content_scripts/duplicate_script_injection/should_run_once.js
@@ -1,13 +1,7 @@
// Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-//
-// Message definitions shared across proto files.
-syntax = "proto2";
-
-option optimize_for = LITE_RUNTIME;
-
-package blimp;
-
-message EmptyMessage {}
+var should_be_injected_once = document.createElement('div');
+should_be_injected_once.className = 'injected-once';
+document.body.appendChild(should_be_injected_once);

Powered by Google App Engine
This is Rietveld 408576698