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

Side by Side Diff: base/test/unit_test_launcher.cc

Issue 23484026: GTTF: kill spawned test processes when the launcher is killed (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: LAZY_INSTANCE_INITIALIZER Created 7 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 | « base/test/test_launcher.cc ('k') | content/public/test/test_launcher.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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/test/unit_test_launcher.h" 5 #include "base/test/unit_test_launcher.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback_helpers.h" 8 #include "base/callback_helpers.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 return 1; 331 return 1;
332 332
333 fprintf(stdout, 333 fprintf(stdout,
334 "Starting tests (using %d parallel jobs)...\n" 334 "Starting tests (using %d parallel jobs)...\n"
335 "IMPORTANT DEBUGGING NOTE: batches of tests are run inside their\n" 335 "IMPORTANT DEBUGGING NOTE: batches of tests are run inside their\n"
336 "own process. For debugging a test inside a debugger, use the\n" 336 "own process. For debugging a test inside a debugger, use the\n"
337 "--gtest_filter=<your_test_name> flag along with\n" 337 "--gtest_filter=<your_test_name> flag along with\n"
338 "--single-process-tests.\n", jobs); 338 "--single-process-tests.\n", jobs);
339 fflush(stdout); 339 fflush(stdout);
340 340
341 MessageLoop message_loop; 341 MessageLoopForIO message_loop;
342 342
343 base::UnitTestLauncherDelegate delegate(jobs, batch_limit); 343 base::UnitTestLauncherDelegate delegate(jobs, batch_limit);
344 int exit_code = base::LaunchTests(&delegate, argc, argv); 344 int exit_code = base::LaunchTests(&delegate, argc, argv);
345 345
346 fprintf(stdout, 346 fprintf(stdout,
347 "Tests took %" PRId64 " seconds.\n", 347 "Tests took %" PRId64 " seconds.\n",
348 (base::TimeTicks::Now() - start_time).InSeconds()); 348 (base::TimeTicks::Now() - start_time).InSeconds());
349 fflush(stdout); 349 fflush(stdout);
350 350
351 return exit_code; 351 return exit_code;
352 } 352 }
353 353
354 } // namespace base 354 } // namespace base
OLDNEW
« no previous file with comments | « base/test/test_launcher.cc ('k') | content/public/test/test_launcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698