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

Side by Side Diff: webrtc/test/test_suite.cc

Issue 1331503002: Disable base/logging.h stderr logs by default for webrtc/ tests. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 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
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
11 #include "webrtc/test/test_suite.h" 11 #include "webrtc/test/test_suite.h"
12 12
13 #include "gflags/gflags.h" 13 #include "gflags/gflags.h"
14 #include "testing/gmock/include/gmock/gmock.h" 14 #include "testing/gmock/include/gmock/gmock.h"
15 #include "testing/gtest/include/gtest/gtest.h" 15 #include "testing/gtest/include/gtest/gtest.h"
16 #include "webrtc/base/logging.h"
16 #include "webrtc/test/testsupport/fileutils.h" 17 #include "webrtc/test/testsupport/fileutils.h"
17 #include "webrtc/test/testsupport/trace_to_stderr.h" 18 #include "webrtc/test/testsupport/trace_to_stderr.h"
18 #include "webrtc/test/field_trial.h" 19 #include "webrtc/test/field_trial.h"
19 20
20 DEFINE_bool(logs, false, "print logs to stderr"); 21 DEFINE_bool(logs, false, "print logs to stderr");
21 22
22 DEFINE_string(force_fieldtrials, "", 23 DEFINE_string(force_fieldtrials, "",
23 "Field trials control experimental feature code which can be forced. " 24 "Field trials control experimental feature code which can be forced. "
24 "E.g. running with --force_fieldtrials=WebRTC-FooFeature/Enable/" 25 "E.g. running with --force_fieldtrials=WebRTC-FooFeature/Enable/"
25 " will assign the group Enable to field trial WebRTC-FooFeature."); 26 " will assign the group Enable to field trial WebRTC-FooFeature.");
(...skipping 16 matching lines...) Expand all
42 } 43 }
43 44
44 int TestSuite::Run() { 45 int TestSuite::Run() {
45 Initialize(); 46 Initialize();
46 int result = RUN_ALL_TESTS(); 47 int result = RUN_ALL_TESTS();
47 Shutdown(); 48 Shutdown();
48 return result; 49 return result;
49 } 50 }
50 51
51 void TestSuite::Initialize() { 52 void TestSuite::Initialize() {
53 rtc::LogMessage::SetLogToStderr(FLAGS_logs);
52 if (FLAGS_logs) 54 if (FLAGS_logs)
53 trace_to_stderr_.reset(new TraceToStderr); 55 trace_to_stderr_.reset(new TraceToStderr);
54 } 56 }
55 57
56 void TestSuite::Shutdown() { 58 void TestSuite::Shutdown() {
57 } 59 }
58 60
59 } // namespace test 61 } // namespace test
60 } // namespace webrtc 62 } // namespace webrtc
OLDNEW
« webrtc/base/logging.cc ('K') | « webrtc/system_wrappers/source/logging.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698