Index: chrome/browser/extensions/socket_apitest.cc |
diff --git a/chrome/browser/extensions/socket_apitest.cc b/chrome/browser/extensions/socket_apitest.cc |
index 9fc9138a84265c53e220f856603bcac60364137c..2d67a5dce8ebae7228baefbb09949f4d2e3c2d91 100644 |
--- a/chrome/browser/extensions/socket_apitest.cc |
+++ b/chrome/browser/extensions/socket_apitest.cc |
@@ -15,15 +15,18 @@ using namespace extension_function_test_utils; |
namespace { |
class SocketApiTest : public InProcessBrowserTest { |
+ public: |
+ virtual void SetUp() { |
+ CommandLine::ForCurrentProcess()->AppendSwitch( |
+ switches::kEnableExperimentalExtensionApis); |
+ CommandLine::ForCurrentProcess()->AppendSwitch( |
+ switches::kEnablePlatformApps); |
+ } |
}; |
} |
IN_PROC_BROWSER_TEST_F(SocketApiTest, SocketCreateGood) { |
- CommandLine::ForCurrentProcess()->AppendSwitch( |
- switches::kEnableExperimentalExtensionApis); |
- CommandLine::ForCurrentProcess()->AppendSwitch( |
- switches::kEnablePlatformApps); |
scoped_refptr<extensions::SocketCreateFunction> socket_create_function( |
new extensions::SocketCreateFunction()); |
scoped_refptr<Extension> empty_extension(CreateEmptyExtension()); |
@@ -41,10 +44,6 @@ IN_PROC_BROWSER_TEST_F(SocketApiTest, SocketCreateGood) { |
} |
IN_PROC_BROWSER_TEST_F(SocketApiTest, SocketCreateBad) { |
- CommandLine::ForCurrentProcess()->AppendSwitch( |
- switches::kEnableExperimentalExtensionApis); |
- CommandLine::ForCurrentProcess()->AppendSwitch( |
- switches::kEnablePlatformApps); |
scoped_refptr<extensions::SocketCreateFunction> socket_create_function( |
new extensions::SocketCreateFunction()); |
scoped_refptr<Extension> empty_extension(CreateEmptyExtension()); |
@@ -59,10 +58,5 @@ IN_PROC_BROWSER_TEST_F(SocketApiTest, SocketCreateBad) { |
} |
IN_PROC_BROWSER_TEST_F(ExtensionApiTest, SocketExtension) { |
- CommandLine::ForCurrentProcess()->AppendSwitch( |
Mihai Parparita -not on Chrome
2011/12/01 23:39:32
This test doesn't inherit from SocketApiTest, so p
|
- switches::kEnableExperimentalExtensionApis); |
- CommandLine::ForCurrentProcess()->AppendSwitch( |
- switches::kEnablePlatformApps); |
- |
ASSERT_TRUE(RunExtensionTest("socket/api")) << message_; |
} |