blob: acce96f2c63d98f0127cc35704e140a90472d798 [file] [log] [blame]
pbos@webrtc.orgaf8d5af2013-07-09 08:02:33 +00001/*
2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved.
3 *
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
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
andresp@webrtc.org60015d22014-05-16 09:39:51 +000011#include "gflags/gflags.h"
pbos@webrtc.orgaf8d5af2013-07-09 08:02:33 +000012#include "testing/gtest/include/gtest/gtest.h"
andresp@webrtc.org60015d22014-05-16 09:39:51 +000013#include "webrtc/test/field_trial.h"
pbos@webrtc.org16e03b72013-10-28 16:32:01 +000014#include "webrtc/test/run_tests.h"
pbos@webrtc.orgfbf0f692013-08-21 16:00:15 +000015#include "webrtc/test/testsupport/fileutils.h"
pbos@webrtc.orgaf8d5af2013-07-09 08:02:33 +000016
andresp@webrtc.org60015d22014-05-16 09:39:51 +000017DEFINE_string(force_fieldtrials, "",
18 "Field trials control experimental feature code which can be forced. "
19 "E.g. running with --force_fieldtrials=WebRTC-FooFeature/Enable/"
20 " will assign the group Enable to field trial WebRTC-FooFeature.");
21
pbos@webrtc.orgaf8d5af2013-07-09 08:02:33 +000022int main(int argc, char* argv[]) {
23 ::testing::InitGoogleTest(&argc, argv);
pbos@webrtc.orgaf8d5af2013-07-09 08:02:33 +000024
andresp@webrtc.org60015d22014-05-16 09:39:51 +000025 // AllowCommandLineParsing allows us to ignore flags passed on to us by
26 // Chromium build bots without having to explicitly disable them.
27 google::AllowCommandLineReparsing();
28 google::ParseCommandLineFlags(&argc, &argv, false);
29
30 webrtc::test::SetExecutablePath(argv[0]);
31 webrtc::test::InitFieldTrialsFromString(FLAGS_force_fieldtrials);
pbos@webrtc.orgaf8d5af2013-07-09 08:02:33 +000032 return webrtc::test::RunAllTests();
33}