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

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

Issue 819133004: Make callers of CommandLine use it via the base:: namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix Created 6 years 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 "base/files/file_path.h" 5 #include "base/files/file_path.h"
6 #include "base/files/scoped_temp_dir.h" 6 #include "base/files/scoped_temp_dir.h"
7 #include "base/threading/sequenced_worker_pool.h" 7 #include "base/threading/sequenced_worker_pool.h"
8 #include "chrome/app/chrome_command_ids.h" 8 #include "chrome/app/chrome_command_ids.h"
9 #include "chrome/browser/extensions/extension_browsertest.h" 9 #include "chrome/browser/extensions/extension_browsertest.h"
10 #include "chrome/browser/extensions/extension_service.h" 10 #include "chrome/browser/extensions/extension_service.h"
(...skipping 15 matching lines...) Expand all
26 #include "sync/protocol/extension_specifics.pb.h" 26 #include "sync/protocol/extension_specifics.pb.h"
27 #include "sync/protocol/sync.pb.h" 27 #include "sync/protocol/sync.pb.h"
28 28
29 using content::BrowserThread; 29 using content::BrowserThread;
30 using extensions::Extension; 30 using extensions::Extension;
31 using extensions::ExtensionRegistry; 31 using extensions::ExtensionRegistry;
32 using extensions::ExtensionPrefs; 32 using extensions::ExtensionPrefs;
33 33
34 class ExtensionDisabledGlobalErrorTest : public ExtensionBrowserTest { 34 class ExtensionDisabledGlobalErrorTest : public ExtensionBrowserTest {
35 protected: 35 protected:
36 void SetUpCommandLine(CommandLine* command_line) override { 36 void SetUpCommandLine(base::CommandLine* command_line) override {
37 ExtensionBrowserTest::SetUpCommandLine(command_line); 37 ExtensionBrowserTest::SetUpCommandLine(command_line);
38 command_line->AppendSwitchASCII(switches::kAppsGalleryUpdateURL, 38 command_line->AppendSwitchASCII(switches::kAppsGalleryUpdateURL,
39 "http://localhost/autoupdate/updates.xml"); 39 "http://localhost/autoupdate/updates.xml");
40 } 40 }
41 41
42 void SetUpOnMainThread() override { 42 void SetUpOnMainThread() override {
43 ExtensionBrowserTest::SetUpOnMainThread(); 43 ExtensionBrowserTest::SetUpOnMainThread();
44 EXPECT_TRUE(scoped_temp_dir_.CreateUniqueTempDir()); 44 EXPECT_TRUE(scoped_temp_dir_.CreateUniqueTempDir());
45 service_ = extensions::ExtensionSystem::Get( 45 service_ = extensions::ExtensionSystem::Get(
46 browser()->profile())->extension_service(); 46 browser()->profile())->extension_service();
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 245
246 const Extension* extension = service_->GetExtensionById(extension_id, true); 246 const Extension* extension = service_->GetExtensionById(extension_id, true);
247 ASSERT_TRUE(extension); 247 ASSERT_TRUE(extension);
248 EXPECT_EQ("2", extension->VersionString()); 248 EXPECT_EQ("2", extension->VersionString());
249 EXPECT_EQ(1u, registry_->disabled_extensions().size()); 249 EXPECT_EQ(1u, registry_->disabled_extensions().size());
250 EXPECT_EQ(Extension::DISABLE_REMOTE_INSTALL, 250 EXPECT_EQ(Extension::DISABLE_REMOTE_INSTALL,
251 ExtensionPrefs::Get(service_->profile()) 251 ExtensionPrefs::Get(service_->profile())
252 ->GetDisableReasons(extension_id)); 252 ->GetDisableReasons(extension_id));
253 EXPECT_TRUE(GetExtensionDisabledGlobalError()); 253 EXPECT_TRUE(GetExtensionDisabledGlobalError());
254 } 254 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_browsertest.cc ('k') | chrome/browser/extensions/extension_gcm_app_handler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698