Chromium Code Reviews| Index: chrome/browser/google_url_tracker_unittest.cc |
| diff --git a/chrome/browser/google_url_tracker_unittest.cc b/chrome/browser/google_url_tracker_unittest.cc |
| index 428a3e335f6b76e28083e3a3a4852236adc5b92c..f0a6d2a2b1a4fc4d135141c610cd02b7cbd9e574 100644 |
| --- a/chrome/browser/google_url_tracker_unittest.cc |
| +++ b/chrome/browser/google_url_tracker_unittest.cc |
| @@ -70,13 +70,16 @@ class TestInfoBarDelegateFactory |
| class GoogleURLTrackerTest : public testing::Test { |
| protected: |
| GoogleURLTrackerTest() |
| - : original_default_request_context_(NULL) { |
| + : message_loop_(NULL), |
| + io_thread_(NULL), |
| + original_default_request_context_(NULL) { |
| } |
| void SetUp() { |
| original_default_request_context_ = Profile::GetDefaultRequestContext(); |
| Profile::set_default_request_context(NULL); |
| message_loop_ = new MessageLoop(MessageLoop::TYPE_IO); |
| + io_thread_ = new ChromeThread(ChromeThread::IO, message_loop_); |
| network_change_notifier_.reset(net::NetworkChangeNotifier::CreateMock()); |
| testing_profile_.reset(new TestingProfile); |
| TestingBrowserProcess* testing_browser_process = |
| @@ -99,8 +102,10 @@ class GoogleURLTrackerTest : public testing::Test { |
| testing_browser_process->SetPrefService(NULL); |
| testing_profile_.reset(); |
| network_change_notifier_.reset(); |
| + delete io_thread_; |
| delete message_loop_; |
| Profile::set_default_request_context(original_default_request_context_); |
| + original_default_request_context_ = NULL; |
| } |
| void CreateRequestContext() { |
| @@ -215,6 +220,7 @@ class GoogleURLTrackerTest : public testing::Test { |
| private: |
| MessageLoop* message_loop_; |
| + ChromeThread* io_thread_; |
|
Paweł Hajdan Jr.
2010/08/23 17:22:48
Why isn't it a scoped_ptr? I suggest we just make
|
| scoped_ptr<net::NetworkChangeNotifier> network_change_notifier_; |
| scoped_ptr<TestingProfile> testing_profile_; |