1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
|
# Copyright 2015 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
declare_args() {
# Many of the targets defined in this file have dependencies that cannot be
# satisfied without additional downstream resources. Explicitly guard them
# them behind this flag so that we do not attempt to build or isolate targets
# in public chromium checkouts.
enable_downstream_media_tests = false
}
source_set("browser_tests") {
testonly = true
defines = [ "HAS_OUT_OF_PROC_TEST_RUNNER" ]
sources = [
"media_router_e2e_browsertest.cc",
"media_router_e2e_browsertest.h",
"media_router_e2e_ui_browsertest.cc",
"media_router_integration_browsertest.cc",
"media_router_integration_browsertest.h",
"media_router_integration_ui_browsertest.cc",
"media_router_one_ua_integration_browsertest.cc",
"media_router_ui_for_test.cc",
"media_router_ui_for_test.h",
]
deps = [
":test_support",
"//chrome/app:generated_resources",
"//chrome/browser",
"//chrome/browser/media/router",
"//chrome/browser/ui",
"//chrome/common",
"//chrome/common/media_router:router",
"//chrome/test:test_support_ui",
"//content/public/browser",
"//content/test:test_support",
"//media:test_support",
"//net",
"//net:test_support",
"//testing/gtest",
"//ui/base",
"//url",
]
data_deps = [
":browser_test_resources",
"//chrome/browser/resources/media_router/extension:media_router",
]
data = [
"$root_gen_dir/chrome/browser/resources/media_router/extension/",
]
}
copy("browser_test_resources") {
testonly = true
sources = [
"resources/basic_test.html",
"resources/close_route_with_error_on_send.json",
"resources/common.js",
"resources/fail_create_route.json",
"resources/fail_reconnect_session.html",
"resources/fail_reconnect_session.json",
"resources/local_media_sink.json",
"resources/local_media_sink_route_fail.json",
"resources/no_presentation_receiver.html",
"resources/no_provider.json",
"resources/no_sinks.json",
"resources/no_supported_sinks.json",
"resources/presentation_receiver.html",
"resources/route_creation_timed_out.json",
]
outputs = [
"$root_out_dir/media_router/browser_test_resources/{{source_file_part}}",
]
}
# Run separately from the Chromium waterfall with the external component
# extension. See README.md
if (enable_downstream_media_tests) {
group("media_router_e2e_tests") {
testonly = true
data_deps = [
":browser_test_resources",
":e2e_test_resources",
"//chrome/test:browser_tests",
]
data = [
"$root_out_dir/mr_extension/",
"internal/",
]
}
}
copy("e2e_test_resources") {
testonly = true
sources = [
"../../../media/test/data/bear-vp9.webm",
"../../../media/test/data/player.html",
]
outputs = [
"$root_out_dir/media_router/browser_test_resources/{{source_file_part}}",
]
}
# Run separately. TODO: Documentation on how to run
if (enable_downstream_media_tests) {
group("swarming_tests") {
testonly = true
data_deps = [
":browser_test_resources",
"//chrome/test:browser_tests",
]
data = [
"internal/",
"$root_out_dir/mr_extension/",
]
}
}
source_set("test_support") {
testonly = true
sources = [
"media_router_base_browsertest.cc",
"media_router_base_browsertest.h",
"test_media_sinks_observer.cc",
"test_media_sinks_observer.h",
]
public_deps = [
"//base",
"//chrome/browser/extensions",
"//extensions/browser",
]
deps = [
"//chrome/browser/media/router",
"//chrome/browser/media/router:test_support",
"//chrome/common:constants",
"//chrome/test:test_support",
"//chrome/test:test_support_ui",
"//content/public/common",
"//content/test:test_support",
"//extensions/common",
"//testing/gtest",
]
}
if (enable_downstream_media_tests) {
group("media_router_perf_tests") {
testonly = true
data = [
"$root_out_dir/media_router/telemetry_extension/",
"$root_out_dir/mr_extension/release/",
"internal/",
"telemetry/",
]
deps = [
"//tools/perf:perf",
]
data_deps = [
"//tools/perf/contrib/media_router_benchmarks:telemetry_extension_resources",
]
}
}
|