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

Side by Side Diff: chrome/browser/extensions/convert_user_script_unittest.cc

Issue 1871713002: Convert //chrome/browser/extensions from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and fix header Created 4 years, 8 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/extensions/convert_user_script.h"
6
7 #include <memory>
5 #include <string> 8 #include <string>
6 #include <vector> 9 #include <vector>
7 10
8 #include "base/files/file_path.h" 11 #include "base/files/file_path.h"
9 #include "base/files/file_util.h" 12 #include "base/files/file_util.h"
10 #include "base/files/scoped_temp_dir.h" 13 #include "base/files/scoped_temp_dir.h"
11 #include "base/memory/scoped_ptr.h"
12 #include "base/path_service.h" 14 #include "base/path_service.h"
13 #include "base/strings/utf_string_conversions.h" 15 #include "base/strings/utf_string_conversions.h"
14 #include "chrome/browser/extensions/convert_user_script.h"
15 #include "chrome/common/chrome_paths.h" 16 #include "chrome/common/chrome_paths.h"
16 #include "chrome/common/extensions/manifest_handlers/content_scripts_handler.h" 17 #include "chrome/common/extensions/manifest_handlers/content_scripts_handler.h"
17 #include "extensions/common/constants.h" 18 #include "extensions/common/constants.h"
18 #include "extensions/common/extension.h" 19 #include "extensions/common/extension.h"
19 #include "testing/gtest/include/gtest/gtest.h" 20 #include "testing/gtest/include/gtest/gtest.h"
20 21
21 namespace extensions { 22 namespace extensions {
22 23
23 namespace { 24 namespace {
24 25
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
252 EXPECT_EQ(Manifest::TYPE_USER_SCRIPT, extension->GetType()); 253 EXPECT_EQ(Manifest::TYPE_USER_SCRIPT, extension->GetType());
253 254
254 // Validate run location. 255 // Validate run location.
255 ASSERT_EQ(1u, ContentScriptsInfo::GetContentScripts(extension.get()).size()); 256 ASSERT_EQ(1u, ContentScriptsInfo::GetContentScripts(extension.get()).size());
256 const UserScript& script = 257 const UserScript& script =
257 ContentScriptsInfo::GetContentScripts(extension.get())[0]; 258 ContentScriptsInfo::GetContentScripts(extension.get())[0];
258 EXPECT_EQ(UserScript::DOCUMENT_IDLE, script.run_location()); 259 EXPECT_EQ(UserScript::DOCUMENT_IDLE, script.run_location());
259 } 260 }
260 261
261 } // namespace extensions 262 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/convert_user_script.cc ('k') | chrome/browser/extensions/convert_web_app.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698