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

Side by Side Diff: webkit/tools/test_shell/run_all_tests.cc

Issue 3105: Enforce Terminate on Heap Corruption in most of our executable on Windows XP ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 12 years, 3 months 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/tools/tld_cleanup/tld_cleanup.cc ('k') | webkit/tools/test_shell/test_shell_main.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 // Run all of our test shell tests. This is just an entry point 5 // Run all of our test shell tests. This is just an entry point
6 // to kick off gTest's RUN_ALL_TESTS(). 6 // to kick off gTest's RUN_ALL_TESTS().
7 7
8 #include <windows.h> 8 #include <windows.h>
9 #include <commctrl.h> 9 #include <commctrl.h>
10 10
11 #include "base/at_exit.h" 11 #include "base/at_exit.h"
12 #include "base/icu_util.h" 12 #include "base/icu_util.h"
13 #include "base/message_loop.h" 13 #include "base/message_loop.h"
14 #include "base/process_util.h"
14 #include "webkit/tools/test_shell/simple_resource_loader_bridge.h" 15 #include "webkit/tools/test_shell/simple_resource_loader_bridge.h"
15 #include "webkit/tools/test_shell/test_shell.h" 16 #include "webkit/tools/test_shell/test_shell.h"
16 #include "webkit/tools/test_shell/test_shell_test.h" 17 #include "webkit/tools/test_shell/test_shell_test.h"
17 #include "testing/gtest/include/gtest/gtest.h" 18 #include "testing/gtest/include/gtest/gtest.h"
18 19
19 const char* TestShellTest::kJavascriptDelayExitScript = 20 const char* TestShellTest::kJavascriptDelayExitScript =
20 "<script>" 21 "<script>"
21 "window.layoutTestController.waitUntilDone();" 22 "window.layoutTestController.waitUntilDone();"
22 "window.addEventListener('load', function() {" 23 "window.addEventListener('load', function() {"
23 " var x = document.body.clientWidth;" // Force a document layout 24 " var x = document.body.clientWidth;" // Force a document layout
24 " window.layoutTestController.notifyDone();" 25 " window.layoutTestController.notifyDone();"
25 "});" 26 "});"
26 "</script>"; 27 "</script>";
27 28
28 int main(int argc, char* argv[]) { 29 int main(int argc, char* argv[]) {
30 process_util::EnableTerminationOnHeapCorruption();
29 // Some unittests may use base::Singleton<>, thus we need to instanciate 31 // Some unittests may use base::Singleton<>, thus we need to instanciate
30 // the AtExitManager or else we will leak objects. 32 // the AtExitManager or else we will leak objects.
31 base::AtExitManager at_exit_manager; 33 base::AtExitManager at_exit_manager;
32 34
33 TestShell::InitLogging(true); // suppress error dialogs 35 TestShell::InitLogging(true); // suppress error dialogs
34 36
35 // Initialize test shell in non-interactive mode, which will let us load one 37 // Initialize test shell in non-interactive mode, which will let us load one
36 // request than automatically quit. 38 // request than automatically quit.
37 TestShell::InitializeTestShell(false); 39 TestShell::InitializeTestShell(false);
38 40
(...skipping 18 matching lines...) Expand all
57 59
58 // Run the actual tests 60 // Run the actual tests
59 testing::InitGoogleTest(&argc, argv); 61 testing::InitGoogleTest(&argc, argv);
60 int result = RUN_ALL_TESTS(); 62 int result = RUN_ALL_TESTS();
61 63
62 TestShell::ShutdownTestShell(); 64 TestShell::ShutdownTestShell();
63 TestShell::CleanupLogging(); 65 TestShell::CleanupLogging();
64 return result; 66 return result;
65 } 67 }
66 68
OLDNEW
« no previous file with comments | « net/tools/tld_cleanup/tld_cleanup.cc ('k') | webkit/tools/test_shell/test_shell_main.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698