From 6910537458829b6326db690031ff2759bc72d6f8 Mon Sep 17 00:00:00 2001 From: maxmorin Date: Tue, 16 Aug 2016 02:17:44 -0700 Subject: [PATCH] Add gn target for audio_device_tests. Note (for myself) that this depends on https://codereview.webrtc.org/2219653004/ and https://codereview.webrtc.org/2214003002/, it should not be landed before them. NOTRY=True BUG=webrtc:6170,webrtc:5949 Review-Url: https://codereview.webrtc.org/2216423002 Cr-Commit-Position: refs/heads/master@{#13773} --- .gn | 1 + webrtc/modules/audio_device/BUILD.gn | 28 ++++++++++++++++++++++++++++ 2 files changed, 29 insertions(+) diff --git a/.gn b/.gn index 4cd7b013e1..75e2587cee 100644 --- a/.gn +++ b/.gn @@ -20,6 +20,7 @@ secondary_source = "//build/secondary/" # "gn check" or "gn gen --check". # TODO(kjellander): Keep adding paths to this list as work in webrtc:5589 is done. check_targets = [ + "//webrtc/modules/audio_device/*", "//webrtc/voice_engine:level_indicator", "//webrtc/modules/audio_coding:isac_fix_test", "//webrtc/modules/audio_mixer:audio_conference_mixer", diff --git a/webrtc/modules/audio_device/BUILD.gn b/webrtc/modules/audio_device/BUILD.gn index 35a99eaac7..369d88af59 100644 --- a/webrtc/modules/audio_device/BUILD.gn +++ b/webrtc/modules/audio_device/BUILD.gn @@ -29,6 +29,7 @@ source_set("audio_device") { "../..:webrtc_common", "../../base:rtc_base", "../../base:rtc_base_approved", + "../../base:rtc_task_queue", "../../common_audio", "../../system_wrappers", "../utility", @@ -210,3 +211,30 @@ source_set("audio_device") { configs -= [ "//build/config/clang:find_bad_constructs" ] } } + +# These tests do not work on ios, see +# https://bugs.chromium.org/p/webrtc/issues/detail?id=4755 +if (rtc_include_tests && !is_ios) { + executable("audio_device_tests") { + testonly = true + sources = [ + "test/audio_device_test_api.cc", + "test/audio_device_test_defines.h", + ] + deps = [ + ":audio_device", + "../..:webrtc_common", + "../../system_wrappers", + "../../test:test_support", + "../../test:test_support_main", + "../rtp_rtcp", + "../utility", + "//testing/gtest", + ] + configs += [ "../..:common_config" ] + public_configs = [ + "../..:common_inherited_config", + ":audio_device_config", + ] + } +}