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

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

Issue 10141008: Make managedMode extension API component-only. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 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 | Annotate | Revision Log
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/managed_mode.h" 5 #include "chrome/browser/managed_mode.h"
6 #include "chrome/browser/extensions/extension_apitest.h" 6 #include "chrome/browser/extensions/extension_apitest.h"
7 #include "chrome/common/chrome_switches.h" 7 #include "chrome/common/chrome_switches.h"
8 8
9 // Tests enabling and querying managed mode. 9 // Tests enabling and querying managed mode.
10 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, ManagedModeGetAndEnable) { 10 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, ManagedModeGetAndEnable) {
11 CommandLine::ForCurrentProcess()->AppendSwitch( 11 CommandLine::ForCurrentProcess()->AppendSwitch(
12 switches::kEnableExperimentalExtensionApis); 12 switches::kEnableExperimentalExtensionApis);
13 13
14 ASSERT_FALSE(ManagedMode::IsInManagedMode()); 14 ASSERT_FALSE(ManagedMode::IsInManagedMode());
15 15
16 ASSERT_TRUE(RunExtensionTest("managedMode")) << message_; 16 ASSERT_TRUE(RunComponentExtensionTest("managedMode")) << message_;
17 const Extension* extension = GetSingleLoadedExtension();
18 ASSERT_TRUE(extension);
19 17
20 EXPECT_TRUE(ManagedMode::IsInManagedMode()); 18 EXPECT_TRUE(ManagedMode::IsInManagedMode());
21 } 19 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_managed_mode_api.h ('k') | chrome/browser/extensions/extension_preference_api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698