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

Unified Diff: chrome/browser/policy/cloud/component_cloud_policy_browsertest.cc

Issue 79023002: Support cloud policy for extensions on the desktop platforms. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixed stub, again Created 7 years, 1 month 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/browser/policy/cloud/component_cloud_policy_browsertest.cc
diff --git a/chrome/browser/policy/cloud/component_cloud_policy_browsertest.cc b/chrome/browser/policy/cloud/component_cloud_policy_browsertest.cc
index 2f5c94d9ce4f01c700756badc61f47872d03f4e0..7adfe8b879fe523a10bffc71abcb5d658a3e27a2 100644
--- a/chrome/browser/policy/cloud/component_cloud_policy_browsertest.cc
+++ b/chrome/browser/policy/cloud/component_cloud_policy_browsertest.cc
@@ -24,7 +24,6 @@
#include "chrome/browser/profiles/profile.h"
#include "chrome/common/chrome_paths.h"
#include "chrome/common/chrome_switches.h"
-#include "components/policy/core/common/policy_switches.h"
#include "extensions/common/extension.h"
#include "net/url_request/url_request_context_getter.h"
#include "policy/proto/cloud_policy.pb.h"
@@ -34,7 +33,6 @@
#if defined(OS_CHROMEOS)
#include "chrome/browser/chromeos/policy/user_cloud_policy_manager_chromeos.h"
#include "chrome/browser/chromeos/policy/user_cloud_policy_manager_factory_chromeos.h"
-#include "chrome/common/chrome_paths.h"
#include "chromeos/chromeos_switches.h"
#else
#include "chrome/browser/policy/cloud/user_cloud_policy_manager.h"
@@ -67,7 +65,6 @@ const char kTestPolicy[] =
" }"
"}";
-#if defined(OS_CHROMEOS)
const char kTestExtension2[] = "behllobkkfkfnphdnhnkndlbkcpglgmj";
const base::FilePath::CharType kTestExtension2Path[] =
FILE_PATH_LITERAL("extensions/managed_extension2");
@@ -82,7 +79,6 @@ const char kTestPolicy2[] =
"}";
const char kTestPolicy2JSON[] = "{\"Another\":\"turn_it_off\"}";
-#endif // defined(OS_CHROMEOS)
class ComponentCloudPolicyTest : public ExtensionBrowserTest {
protected:
@@ -109,7 +105,6 @@ class ComponentCloudPolicyTest : public ExtensionBrowserTest {
std::string url = test_server_.GetServiceURL().spec();
CommandLine* command_line = CommandLine::ForCurrentProcess();
command_line->AppendSwitchASCII(::switches::kDeviceManagementUrl, url);
- command_line->AppendSwitch(switches::kEnableComponentCloudPolicy);
ExtensionBrowserTest::SetUpInProcessBrowserTestFixture();
}
@@ -201,9 +196,6 @@ class ComponentCloudPolicyTest : public ExtensionBrowserTest {
scoped_ptr<ExtensionTestMessageListener> event_listener_;
};
-// TODO(joaodasilva): enable these for other platforms once ready.
-#if defined(OS_CHROMEOS)
-
IN_PROC_BROWSER_TEST_F(ComponentCloudPolicyTest, FetchExtensionPolicy) {
// Read the initial policy.
ExtensionTestMessageListener policy_listener(kTestPolicyJSON, true);
@@ -254,6 +246,4 @@ IN_PROC_BROWSER_TEST_F(ComponentCloudPolicyTest, InstallNewExtension) {
EXPECT_TRUE(result_listener.WaitUntilSatisfied());
}
-#endif // OS_CHROMEOS
-
} // namespace policy

Powered by Google App Engine
This is Rietveld 408576698