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

Side by Side Diff: chrome/test/base/in_process_browser_test.h

Issue 10836148: Don't print the callstack in forked browser test processes. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: simplify Created 8 years, 4 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 | « no previous file | chrome/test/base/in_process_browser_test.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) 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 #ifndef CHROME_TEST_BASE_IN_PROCESS_BROWSER_TEST_H_ 5 #ifndef CHROME_TEST_BASE_IN_PROCESS_BROWSER_TEST_H_
6 #define CHROME_TEST_BASE_IN_PROCESS_BROWSER_TEST_H_ 6 #define CHROME_TEST_BASE_IN_PROCESS_BROWSER_TEST_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 // doesn't apply to the Mac. 166 // doesn't apply to the Mac.
167 CommandLine GetCommandLineForRelaunch(); 167 CommandLine GetCommandLineForRelaunch();
168 #endif 168 #endif
169 169
170 // Returns the host resolver being used for the tests. Subclasses might want 170 // Returns the host resolver being used for the tests. Subclasses might want
171 // to configure it inside tests. 171 // to configure it inside tests.
172 net::RuleBasedHostResolverProc* host_resolver() { 172 net::RuleBasedHostResolverProc* host_resolver() {
173 return host_resolver_.get(); 173 return host_resolver_.get();
174 } 174 }
175 175
176 #if defined(OS_POSIX)
177 // This is only needed by a test that raises SIGTERM to ensure that a specific
178 // codepath is taken.
179 void DisableSIGTERMHandling() {
180 handle_sigterm_ = false;
181 }
182 #endif
183
184 #if defined(OS_MACOSX) 176 #if defined(OS_MACOSX)
185 // Returns the autorelease pool in use inside RunTestOnMainThreadLoop(). 177 // Returns the autorelease pool in use inside RunTestOnMainThreadLoop().
186 base::mac::ScopedNSAutoreleasePool* AutoreleasePool() const { 178 base::mac::ScopedNSAutoreleasePool* AutoreleasePool() const {
187 return autorelease_pool_; 179 return autorelease_pool_;
188 } 180 }
189 #endif // OS_MACOSX 181 #endif // OS_MACOSX
190 182
191 private: 183 private:
192 // Creates a user data directory for the test if one is needed. Returns true 184 // Creates a user data directory for the test if one is needed. Returns true
193 // if successful. 185 // if successful.
(...skipping 12 matching lines...) Expand all
206 // ContentRendererClient when running in single-process mode. 198 // ContentRendererClient when running in single-process mode.
207 scoped_ptr<content::ContentRendererClient> single_process_renderer_client_; 199 scoped_ptr<content::ContentRendererClient> single_process_renderer_client_;
208 200
209 // Host resolver to use during the test. 201 // Host resolver to use during the test.
210 scoped_refptr<net::RuleBasedHostResolverProc> host_resolver_; 202 scoped_refptr<net::RuleBasedHostResolverProc> host_resolver_;
211 203
212 // Temporary user data directory. Used only when a user data directory is not 204 // Temporary user data directory. Used only when a user data directory is not
213 // specified in the command line. 205 // specified in the command line.
214 ScopedTempDir temp_user_data_dir_; 206 ScopedTempDir temp_user_data_dir_;
215 207
216 #if defined(OS_POSIX)
217 bool handle_sigterm_;
218 #endif
219
220 #if defined(OS_CHROMEOS) 208 #if defined(OS_CHROMEOS)
221 chromeos::ScopedStubCrosEnabler stub_cros_enabler_; 209 chromeos::ScopedStubCrosEnabler stub_cros_enabler_;
222 #endif // defined(OS_CHROMEOS) 210 #endif // defined(OS_CHROMEOS)
223 211
224 #if defined(OS_MACOSX) 212 #if defined(OS_MACOSX)
225 base::mac::ScopedNSAutoreleasePool* autorelease_pool_; 213 base::mac::ScopedNSAutoreleasePool* autorelease_pool_;
226 #endif // OS_MACOSX 214 #endif // OS_MACOSX
227 }; 215 };
228 216
229 #endif // CHROME_TEST_BASE_IN_PROCESS_BROWSER_TEST_H_ 217 #endif // CHROME_TEST_BASE_IN_PROCESS_BROWSER_TEST_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/test/base/in_process_browser_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698