GN: move webrtc/video/ targets from webrtc/BUILD.gn into webrtc/video/BUILD.gn

Move the following targets into webrtc/video/BUILD.gn:
* screenshare_loopback
* video_quality_test
* video_loopback

Add new target 'run_tests' in webrtc/test/BUILD.gn, being used by two
of the above and make then depend on that instead.

BUG=webrtc:6440
NOTRY=True

Review-Url: https://codereview.webrtc.org/2438973002
Cr-Commit-Position: refs/heads/master@{#14735}
This commit is contained in:
kjellander 2016-10-24 01:52:39 -07:00 committed by Commit bot
parent 43536c3d6a
commit a3cac0514a
3 changed files with 79 additions and 79 deletions

View File

@ -612,26 +612,6 @@ if (rtc_include_tests) {
}
}
rtc_source_set("video_quality_test") {
testonly = true
sources = [
"video/video_quality_test.cc",
"video/video_quality_test.h",
]
deps = [
":webrtc",
"system_wrappers",
"//testing/gtest",
]
if (!is_android) {
deps += [ "modules/video_capture:video_capture_internal_impl" ]
}
if (!build_with_chromium && is_clang) {
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
webrtc_perf_tests_resources = [
"//resources/audio_coding/speech_mono_16kHz.pcm",
"//resources/audio_coding/testfile32kHz.pcm",
@ -666,63 +646,6 @@ if (rtc_include_tests) {
]
}
rtc_executable("video_loopback") {
testonly = true
sources = [
"test/run_test.h",
"video/video_loopback.cc",
]
if (is_mac) {
sources += [ "test/mac/run_test.mm" ]
} else {
sources += [ "test/run_test.cc" ]
}
deps = [
":video_quality_test",
"system_wrappers:metrics_default",
"test:field_trial",
"test:test_common",
"test:test_renderer",
"//testing/gmock",
"//testing/gtest",
"//third_party/gflags",
]
if (!build_with_chromium && is_clang) {
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
rtc_executable("screenshare_loopback") {
testonly = true
sources = [
"test/run_test.h",
"video/screenshare_loopback.cc",
]
if (is_mac) {
sources += [ "test/mac/run_test.mm" ]
} else {
sources += [ "test/run_test.cc" ]
}
deps = [
":video_quality_test",
"system_wrappers:metrics_default",
"test:field_trial",
"test:test_common",
"test:test_renderer",
"//testing/gmock",
"//testing/gtest",
"//third_party/gflags",
]
if (is_clang && !is_nacl) {
# Suppress warnings from Chrome's Clang plugins.
# See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
rtc_test("webrtc_perf_tests") {
testonly = true
configs += [ ":rtc_unittests_config" ]
@ -738,8 +661,6 @@ if (rtc_include_tests) {
"video/full_stack.cc",
]
deps = [
":video_quality_test",
":webrtc",
"modules/audio_coding:neteq_test_support",
"modules/audio_processing",
"modules/audio_processing:audioproc_test_utils",
@ -748,6 +669,7 @@ if (rtc_include_tests) {
"test:test_common",
"test:test_main",
"test:test_renderer",
"video:video_quality_test",
"voice_engine",
"//testing/gmock",
"//testing/gtest",

View File

@ -193,6 +193,18 @@ rtc_source_set("test_support_main_threaded_mac") {
]
}
rtc_source_set("run_test") {
testonly = true
sources = [
"run_test.h",
]
if (is_mac) {
sources += [ "mac/run_test.mm" ]
} else {
sources += [ "run_test.cc" ]
}
}
test_support_unittests_resources = [
"//resources/foreman_cif_short.yuv",
"//resources/video_coding/frame-ethernet-ii.pcap",
@ -322,6 +334,7 @@ rtc_source_set("test_common") {
"../base:rtc_base_approved",
"../call",
"../modules/media_file",
"../modules/video_capture:video_capture_module",
"../video",
"//testing/gmock",
"//testing/gtest",

View File

@ -73,6 +73,71 @@ rtc_static_library("video") {
}
if (rtc_include_tests) {
rtc_source_set("video_quality_test") {
testonly = true
sources = [
"video_quality_test.cc",
"video_quality_test.h",
]
deps = [
"../system_wrappers",
"//testing/gtest",
]
if (!is_android) {
deps += [ "../modules/video_capture:video_capture_internal_impl" ]
}
if (!build_with_chromium && is_clang) {
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
rtc_executable("video_loopback") {
testonly = true
sources = [
"video_loopback.cc",
]
deps = [
":video_quality_test",
"../system_wrappers:metrics_default",
"../test:field_trial",
"../test:run_test",
"../test:test_common",
"../test:test_renderer",
"//testing/gmock",
"//testing/gtest",
"//third_party/gflags",
]
if (!build_with_chromium && is_clang) {
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
rtc_executable("screenshare_loopback") {
testonly = true
sources = [
"screenshare_loopback.cc",
]
deps = [
":video_quality_test",
"../system_wrappers:metrics_default",
"../test:field_trial",
"../test:run_test",
"../test:test_common",
"../test:test_renderer",
"//testing/gmock",
"//testing/gtest",
"//third_party/gflags",
]
if (!build_with_chromium && is_clang) {
# Suppress warnings from Chrome's Clang plugins.
# See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
# TODO(pbos): Rename test suite.
rtc_source_set("video_tests") {
testonly = true