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

Unified Diff: chrome/browser/io_thread_unittest.cc

Issue 2479593006: Move enable extensions define to a build flag. (Closed)
Patch Set: Merge Created 4 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
« no previous file with comments | « chrome/browser/io_thread.cc ('k') | chrome/browser/loader/chrome_resource_dispatcher_host_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/io_thread_unittest.cc
diff --git a/chrome/browser/io_thread_unittest.cc b/chrome/browser/io_thread_unittest.cc
index 736958edb690fff7eee19041302dd3ba70ba4c46..da1bd4974e9e0334e5a1abb24f873d8b4cecce52 100644
--- a/chrome/browser/io_thread_unittest.cc
+++ b/chrome/browser/io_thread_unittest.cc
@@ -24,6 +24,7 @@
#include "components/variations/variations_associated_data.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/test/test_browser_thread_bundle.h"
+#include "extensions/features/features.h"
#include "net/cert_net/nss_ocsp.h"
#include "net/http/http_auth_preferences.h"
#include "net/http/http_auth_scheme.h"
@@ -33,7 +34,7 @@
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
-#if defined(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_EXTENSIONS)
#include "chrome/browser/extensions/event_router_forwarder.h"
#endif
@@ -106,7 +107,7 @@ class IOThreadTestWithIOThreadObject : public testing::Test {
IOThreadTestWithIOThreadObject()
: thread_bundle_(content::TestBrowserThreadBundle::REAL_IO_THREAD |
content::TestBrowserThreadBundle::DONT_START_THREADS) {
-#if defined(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_EXTENSIONS)
event_router_forwarder_ = new extensions::EventRouterForwarder;
#endif
PrefRegistrySimple* pref_registry = pref_service_.registry();
@@ -128,7 +129,7 @@ class IOThreadTestWithIOThreadObject : public testing::Test {
// The IOThread constructor registers the IOThread object with as the
// BrowserThreadDelegate for the io thread.
io_thread_.reset(new IOThread(&pref_service_, &policy_service_, nullptr,
-#if defined(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_EXTENSIONS)
event_router_forwarder_.get()
#else
nullptr
@@ -163,7 +164,7 @@ class IOThreadTestWithIOThreadObject : public testing::Test {
private:
base::ShadowingAtExitManager at_exit_manager_;
TestingPrefServiceSimple pref_service_;
-#if defined(ENABLE_EXTENSIONS)
+#if BUILDFLAG(ENABLE_EXTENSIONS)
scoped_refptr<extensions::EventRouterForwarder> event_router_forwarder_;
#endif
policy::PolicyMap policy_map_;
« no previous file with comments | « chrome/browser/io_thread.cc ('k') | chrome/browser/loader/chrome_resource_dispatcher_host_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698