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

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

Issue 10536207: Remove layoutTestController from test_shell. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: really fix mac Created 8 years, 6 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 | « webkit/tools/test_shell/layout_test_controller.cc ('k') | webkit/tools/test_shell/test_shell.h » ('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) 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 // 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 "base/basictypes.h" 8 #include "base/basictypes.h"
9 9
10 #if defined(OS_WIN) 10 #if defined(OS_WIN)
(...skipping 14 matching lines...) Expand all
25 #include "webkit/tools/test_shell/test_shell_webkit_init.h" 25 #include "webkit/tools/test_shell/test_shell_webkit_init.h"
26 #include "testing/gtest/include/gtest/gtest.h" 26 #include "testing/gtest/include/gtest/gtest.h"
27 27
28 #if defined(OS_MACOSX) 28 #if defined(OS_MACOSX)
29 #include "base/mac/bundle_locations.h" 29 #include "base/mac/bundle_locations.h"
30 #include "base/mac/mac_util.h" 30 #include "base/mac/mac_util.h"
31 #include "base/mac/scoped_nsautorelease_pool.h" 31 #include "base/mac/scoped_nsautorelease_pool.h"
32 #include "base/path_service.h" 32 #include "base/path_service.h"
33 #endif 33 #endif
34 34
35 const char* const TestShellTest::kJavascriptDelayExitScript =
36 "<script>"
37 "window.layoutTestController.waitUntilDone();"
38 "window.addEventListener('load', function() {"
39 " var x = document.body.clientWidth;" // Force a document layout
40 " window.layoutTestController.notifyDone();"
41 "});"
42 "</script>";
43
44 class TestShellTestSuite : public base::TestSuite { 35 class TestShellTestSuite : public base::TestSuite {
45 public: 36 public:
46 TestShellTestSuite(int argc, char** argv) 37 TestShellTestSuite(int argc, char** argv)
47 : base::TestSuite(argc, argv), 38 : base::TestSuite(argc, argv),
48 platform_delegate_(*CommandLine::ForCurrentProcess()), 39 platform_delegate_(*CommandLine::ForCurrentProcess()),
49 test_shell_webkit_init_(true) { 40 test_shell_webkit_init_(true) {
50 } 41 }
51 42
52 virtual void Initialize() { 43 virtual void Initialize() {
53 // Override DIR_EXE early in case anything in base::TestSuite uses it. 44 // Override DIR_EXE early in case anything in base::TestSuite uses it.
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 }; 98 };
108 99
109 int main(int argc, char** argv) { 100 int main(int argc, char** argv) {
110 #if defined(OS_MACOSX) 101 #if defined(OS_MACOSX)
111 base::mac::ScopedNSAutoreleasePool scoped_pool; 102 base::mac::ScopedNSAutoreleasePool scoped_pool;
112 #endif 103 #endif
113 104
114 TestShellPlatformDelegate::PreflightArgs(&argc, &argv); 105 TestShellPlatformDelegate::PreflightArgs(&argc, &argv);
115 return TestShellTestSuite(argc, argv).Run(); 106 return TestShellTestSuite(argc, argv).Run();
116 } 107 }
OLDNEW
« no previous file with comments | « webkit/tools/test_shell/layout_test_controller.cc ('k') | webkit/tools/test_shell/test_shell.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698