blob: db17c31e44e78f250451e7ccfcda2f33eaedd63c [file] [log] [blame]
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +00001# Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
2#
3# Use of this source code is governed by a BSD-style license
4# that can be found in the LICENSE file in the root of the source
5# tree. An additional intellectual property rights grant can be found
6# in the file PATENTS. All contributing project authors may
7# be found in the AUTHORS file in the root of the source tree.
8
9# TODO(kjellander): Convert the rest of the test.gyp targets and put here.
10
11source_set("test") {
12 testonly = true
13
14 deps = [
15 ":field_trial",
16 ":test_support",
17 ":test_support_main",
18 ]
19}
20
21source_set("field_trial") {
22 sources = [
23 "field_trial.cc",
24 "field_trial.h",
25 ]
26
27 deps = [
28 "../system_wrappers",
29 ]
30
kjellander@webrtc.org3037bc32014-09-30 19:07:58 +000031 configs += [ "..:common_config" ]
32 public_configs = [ "..:common_inherited_config"]
33
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +000034 if (is_clang) {
35 # Suppress warnings from Chrome's Clang plugins.
36 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
37 configs -= [ "//build/config/clang:find_bad_constructs" ]
38 }
39}
40
41source_set("test_support") {
42 testonly = true
43
44 sources = [
45 "testsupport/fileutils.cc",
46 "testsupport/fileutils.h",
47 "testsupport/frame_reader.cc",
48 "testsupport/frame_reader.h",
49 "testsupport/frame_writer.cc",
50 "testsupport/frame_writer.h",
51 "testsupport/gtest_prod_util.h",
52 "testsupport/gtest_disable.h",
53 "testsupport/mock/mock_frame_reader.h",
54 "testsupport/mock/mock_frame_writer.h",
55 "testsupport/packet_reader.cc",
56 "testsupport/packet_reader.h",
57 "testsupport/perf_test.cc",
58 "testsupport/perf_test.h",
59 "testsupport/trace_to_stderr.cc",
60 "testsupport/trace_to_stderr.h",
61 ]
62
63 deps = [
64 "//testing/gmock",
65 "//testing/gtest",
66 "../system_wrappers",
67 ]
68
69 if (is_android) {
70 sources += [ "testsupport/android/root_path_android_chromium.cc" ]
71 deps += [ "//base:base" ]
72 } else {
73 sources += [ "testsupport/android/root_path_android.cc" ]
74 }
75
kjellander@webrtc.org3037bc32014-09-30 19:07:58 +000076 configs += [ "..:common_config" ]
77 public_configs = [ "..:common_inherited_config"]
78
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +000079 if (is_clang) {
80 # Suppress warnings from Chrome's Clang plugins.
81 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
82 configs -= [ "//build/config/clang:find_bad_constructs" ]
83 }
84}
85
86source_set("test_support_main") {
87 testonly = true
88
89 sources = [
90 "run_all_unittests.cc",
91 "test_suite.cc",
92 "test_suite.h",
93 ]
94
95 deps = [
96 ":field_trial",
97 ":test_support",
asapersson@webrtc.org580d3672014-10-23 12:57:56 +000098 "../system_wrappers:metrics_default",
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +000099 "//testing/gmock",
100 "//testing/gtest",
101 "//third_party/gflags",
102 ]
103
kjellander@webrtc.org3037bc32014-09-30 19:07:58 +0000104 configs += [ "..:common_config" ]
105 public_configs = [ "..:common_inherited_config"]
106
kjellander@webrtc.orgb8caf6a2014-09-30 18:05:02 +0000107 if (is_clang) {
108 # Suppress warnings from Chrome's Clang plugins.
109 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
110 configs -= [ "//build/config/clang:find_bad_constructs" ]
111 }
112}