| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <atlbase.h> | 7 #include <atlbase.h> |
| 8 #include <atlcom.h> | 8 #include <atlcom.h> |
| 9 #include <exdisp.h> | 9 #include <exdisp.h> |
| 10 #include <Winsock2.h> | 10 #include <Winsock2.h> |
| (...skipping 881 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 892 | 892 |
| 893 #ifndef NDEBUG | 893 #ifndef NDEBUG |
| 894 // Avoid CRT cleanup in debug test runs to ensure that webkit ASSERTs which | 894 // Avoid CRT cleanup in debug test runs to ensure that webkit ASSERTs which |
| 895 // check if globals are created and destroyed on the same thread don't fire. | 895 // check if globals are created and destroyed on the same thread don't fire. |
| 896 // Webkit global objects are created on the inproc renderer thread. | 896 // Webkit global objects are created on the inproc renderer thread. |
| 897 ::ExitProcess(test_result()); | 897 ::ExitProcess(test_result()); |
| 898 #endif | 898 #endif |
| 899 } | 899 } |
| 900 | 900 |
| 901 void CFUrlRequestUnittestRunner::StartFileLogger() { | 901 void CFUrlRequestUnittestRunner::StartFileLogger() { |
| 902 if (file_util::CreateTemporaryFile(&log_file_)) { | 902 if (base::CreateTemporaryFile(&log_file_)) { |
| 903 file_logger_.reset(new logging_win::FileLogger()); | 903 file_logger_.reset(new logging_win::FileLogger()); |
| 904 file_logger_->Initialize(); | 904 file_logger_->Initialize(); |
| 905 file_logger_->StartLogging(log_file_); | 905 file_logger_->StartLogging(log_file_); |
| 906 } else { | 906 } else { |
| 907 LOG(ERROR) << "Failed to create an ETW log file"; | 907 LOG(ERROR) << "Failed to create an ETW log file"; |
| 908 } | 908 } |
| 909 } | 909 } |
| 910 | 910 |
| 911 void CFUrlRequestUnittestRunner::StopFileLogger(bool print) { | 911 void CFUrlRequestUnittestRunner::StopFileLogger(bool print) { |
| 912 if (file_logger_.get() != NULL && file_logger_->is_logging()) { | 912 if (file_logger_.get() != NULL && file_logger_->is_logging()) { |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1008 content::InitializeSandboxInfo(&sandbox_info); | 1008 content::InitializeSandboxInfo(&sandbox_info); |
| 1009 FakeMainDelegate delegate; | 1009 FakeMainDelegate delegate; |
| 1010 content::ContentMain( | 1010 content::ContentMain( |
| 1011 reinterpret_cast<HINSTANCE>(GetModuleHandle(NULL)), | 1011 reinterpret_cast<HINSTANCE>(GetModuleHandle(NULL)), |
| 1012 &sandbox_info, | 1012 &sandbox_info, |
| 1013 &delegate); | 1013 &delegate); |
| 1014 | 1014 |
| 1015 // Note: In debug builds, we ExitProcess during PostDestroyThreads. | 1015 // Note: In debug builds, we ExitProcess during PostDestroyThreads. |
| 1016 return g_test_suite->test_result(); | 1016 return g_test_suite->test_result(); |
| 1017 } | 1017 } |
| OLD | NEW |