OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 | 10 |
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
377 if (PromptAfterSetup()) | 377 if (PromptAfterSetup()) |
378 MessageBoxA(NULL, "click ok to exit", "", MB_OK); | 378 MessageBoxA(NULL, "click ok to exit", "", MB_OK); |
379 | 379 |
380 me->ShutDownHostBrowser(); | 380 me->ShutDownHostBrowser(); |
381 } | 381 } |
382 | 382 |
383 void CFUrlRequestUnittestRunner::InitializeLogging() { | 383 void CFUrlRequestUnittestRunner::InitializeLogging() { |
384 FilePath exe; | 384 FilePath exe; |
385 PathService::Get(base::FILE_EXE, &exe); | 385 PathService::Get(base::FILE_EXE, &exe); |
386 FilePath log_filename = exe.ReplaceExtension(FILE_PATH_LITERAL("log")); | 386 FilePath log_filename = exe.ReplaceExtension(FILE_PATH_LITERAL("log")); |
387 logging::InitLogging( | 387 logging::InitLogging(log_filename.value().c_str(), |
388 log_filename.value().c_str(), | 388 logging::LOG_TO_BOTH_FILE_AND_SYSTEM_DEBUG_LOG, |
389 logging::LOG_TO_BOTH_FILE_AND_SYSTEM_DEBUG_LOG, | 389 logging::LOCK_LOG_FILE, |
390 logging::LOCK_LOG_FILE, | 390 logging::DELETE_OLD_LOG_FILE); |
391 logging::DELETE_OLD_LOG_FILE, | |
392 logging::DISABLE_DCHECK_FOR_NON_OFFICIAL_RELEASE_BUILDS); | |
393 // We want process and thread IDs because we may have multiple processes. | 391 // We want process and thread IDs because we may have multiple processes. |
394 // Note: temporarily enabled timestamps in an effort to catch bug 6361. | 392 // Note: temporarily enabled timestamps in an effort to catch bug 6361. |
395 logging::SetLogItems(true, true, true, true); | 393 logging::SetLogItems(true, true, true, true); |
396 } | 394 } |
397 | 395 |
398 void FilterDisabledTests() { | 396 void FilterDisabledTests() { |
399 if (::testing::FLAGS_gtest_filter.length() && | 397 if (::testing::FLAGS_gtest_filter.length() && |
400 ::testing::FLAGS_gtest_filter.Compare("*") != 0) { | 398 ::testing::FLAGS_gtest_filter.Compare("*") != 0) { |
401 // Don't override user specified filters. | 399 // Don't override user specified filters. |
402 return; | 400 return; |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
496 // See url_request_unittest.cc for these credentials. | 494 // See url_request_unittest.cc for these credentials. |
497 SupplyProxyCredentials credentials("user", "secret"); | 495 SupplyProxyCredentials credentials("user", "secret"); |
498 watchdog.AddObserver(&credentials, "Windows Security", ""); | 496 watchdog.AddObserver(&credentials, "Windows Security", ""); |
499 testing::InitGoogleTest(&argc, argv); | 497 testing::InitGoogleTest(&argc, argv); |
500 FilterDisabledTests(); | 498 FilterDisabledTests(); |
501 PluginService::EnableChromePlugins(false); | 499 PluginService::EnableChromePlugins(false); |
502 CFUrlRequestUnittestRunner test_suite(argc, argv); | 500 CFUrlRequestUnittestRunner test_suite(argc, argv); |
503 test_suite.RunMainUIThread(); | 501 test_suite.RunMainUIThread(); |
504 return 0; | 502 return 0; |
505 } | 503 } |
OLD | NEW |