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

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

Issue 6933035: Revert 84284 - Merge gpu_trace_event back into base/debug/trace_event.Initial land attempt at htt... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 7 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/glue/webkitclient_impl.cc ('k') | webkit/tools/test_shell/test_shell_switches.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) 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 "base/at_exit.h" 5 #include "base/at_exit.h"
6 #include "base/basictypes.h" 6 #include "base/basictypes.h"
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/debug/trace_event.h" 8 #include "base/debug/trace_event.h"
9 #include "base/environment.h" 9 #include "base/environment.h"
10 #include "base/event_recorder.h" 10 #include "base/event_recorder.h"
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
151 // Initialize WebKit for this scope. 151 // Initialize WebKit for this scope.
152 TestShellWebKitInit test_shell_webkit_init(layout_test_mode); 152 TestShellWebKitInit test_shell_webkit_init(layout_test_mode);
153 153
154 // Suppress abort message in v8 library in debugging mode (but not 154 // Suppress abort message in v8 library in debugging mode (but not
155 // actually under a debugger). V8 calls abort() when it hits 155 // actually under a debugger). V8 calls abort() when it hits
156 // assertion errors. 156 // assertion errors.
157 if (suppress_error_dialogs) { 157 if (suppress_error_dialogs) {
158 platform.SuppressErrorReporting(); 158 platform.SuppressErrorReporting();
159 } 159 }
160 160
161 if (parsed_command_line.HasSwitch(test_shell::kEnableTracing))
162 base::debug::TraceLog::StartTracing();
163
161 net::HttpCache::Mode cache_mode = net::HttpCache::NORMAL; 164 net::HttpCache::Mode cache_mode = net::HttpCache::NORMAL;
162 165
163 // This is a special mode where JS helps the browser implement 166 // This is a special mode where JS helps the browser implement
164 // playback/record mode. Generally, in this mode, some functions 167 // playback/record mode. Generally, in this mode, some functions
165 // of client-side randomness are removed. For example, in 168 // of client-side randomness are removed. For example, in
166 // this mode Math.random() and Date.getTime() may not return 169 // this mode Math.random() and Date.getTime() may not return
167 // values which vary. 170 // values which vary.
168 bool playback_mode = 171 bool playback_mode =
169 parsed_command_line.HasSwitch(test_shell::kPlaybackMode); 172 parsed_command_line.HasSwitch(test_shell::kPlaybackMode);
170 bool record_mode = 173 bool record_mode =
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
343 TestShell::ShutdownTestShell(); 346 TestShell::ShutdownTestShell();
344 TestShell::CleanupLogging(); 347 TestShell::CleanupLogging();
345 348
346 // Tear down shared StatsTable; prevents unit_tests from leaking it. 349 // Tear down shared StatsTable; prevents unit_tests from leaking it.
347 base::StatsTable::set_current(NULL); 350 base::StatsTable::set_current(NULL);
348 delete table; 351 delete table;
349 RemoveSharedMemoryFile(stats_filename); 352 RemoveSharedMemoryFile(stats_filename);
350 353
351 return 0; 354 return 0;
352 } 355 }
OLDNEW
« no previous file with comments | « webkit/glue/webkitclient_impl.cc ('k') | webkit/tools/test_shell/test_shell_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698