OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_frame/test/net/fake_external_tab.h" | 5 #include "chrome_frame/test/net/fake_external_tab.h" |
6 | 6 |
7 #include <exdisp.h> | 7 #include <exdisp.h> |
8 | 8 |
9 #include "app/app_paths.h" | 9 #include "app/app_paths.h" |
10 #include "app/resource_bundle.h" | 10 #include "app/resource_bundle.h" |
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 browser_process_.reset(); | 135 browser_process_.reset(); |
136 g_browser_process = NULL; | 136 g_browser_process = NULL; |
137 process_singleton_.reset(); | 137 process_singleton_.reset(); |
138 | 138 |
139 ResourceBundle::CleanupSharedInstance(); | 139 ResourceBundle::CleanupSharedInstance(); |
140 } | 140 } |
141 | 141 |
142 CFUrlRequestUnittestRunner::CFUrlRequestUnittestRunner(int argc, char** argv) | 142 CFUrlRequestUnittestRunner::CFUrlRequestUnittestRunner(int argc, char** argv) |
143 : NetTestSuite(argc, argv), | 143 : NetTestSuite(argc, argv), |
144 chrome_frame_html_("/chrome_frame", kChromeFrameHtml) { | 144 chrome_frame_html_("/chrome_frame", kChromeFrameHtml) { |
| 145 // Register the main thread by instantiating it, but don't call any methods. |
| 146 main_thread_.reset(new ChromeThread(ChromeThread::UI, |
| 147 MessageLoop::current())); |
| 148 DCHECK(ChromeThread::CurrentlyOn(ChromeThread::UI)); |
145 fake_chrome_.Initialize(); | 149 fake_chrome_.Initialize(); |
146 pss_subclass_.reset(new ProcessSingletonSubclass(this)); | 150 pss_subclass_.reset(new ProcessSingletonSubclass(this)); |
147 EXPECT_TRUE(pss_subclass_->Subclass(fake_chrome_.user_data())); | 151 EXPECT_TRUE(pss_subclass_->Subclass(fake_chrome_.user_data())); |
148 StartChromeFrameInHostBrowser(); | 152 StartChromeFrameInHostBrowser(); |
149 // Register the main thread by instantiating it, but don't call any methods. | |
150 main_thread_.reset(new ChromeThread(ChromeThread::UI, | |
151 MessageLoop::current())); | |
152 DCHECK(ChromeThread::CurrentlyOn(ChromeThread::UI)); | |
153 } | 153 } |
154 | 154 |
155 CFUrlRequestUnittestRunner::~CFUrlRequestUnittestRunner() { | 155 CFUrlRequestUnittestRunner::~CFUrlRequestUnittestRunner() { |
156 fake_chrome_.Shutdown(); | 156 fake_chrome_.Shutdown(); |
157 } | 157 } |
158 | 158 |
159 DWORD WINAPI NavigateIE(void* param) { | 159 DWORD WINAPI NavigateIE(void* param) { |
160 return 0; | 160 return 0; |
161 win_util::ScopedCOMInitializer com; | 161 win_util::ScopedCOMInitializer com; |
162 BSTR url = reinterpret_cast<BSTR>(param); | 162 BSTR url = reinterpret_cast<BSTR>(param); |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
384 DialogWatchdog watchdog; | 384 DialogWatchdog watchdog; |
385 // See url_request_unittest.cc for these credentials. | 385 // See url_request_unittest.cc for these credentials. |
386 SupplyProxyCredentials credentials("user", "secret"); | 386 SupplyProxyCredentials credentials("user", "secret"); |
387 watchdog.AddObserver(&credentials); | 387 watchdog.AddObserver(&credentials); |
388 testing::InitGoogleTest(&argc, argv); | 388 testing::InitGoogleTest(&argc, argv); |
389 FilterDisabledTests(); | 389 FilterDisabledTests(); |
390 CFUrlRequestUnittestRunner test_suite(argc, argv); | 390 CFUrlRequestUnittestRunner test_suite(argc, argv); |
391 test_suite.RunMainUIThread(); | 391 test_suite.RunMainUIThread(); |
392 return 0; | 392 return 0; |
393 } | 393 } |
OLD | NEW |