From 28a0ffdd52d9ea0063c8344881f909832796e1e0 Mon Sep 17 00:00:00 2001 From: kjellander Date: Wed, 24 Aug 2016 07:48:42 -0700 Subject: [PATCH] GN: Synchronize resources between Android and iOS. iOS tests packaged into an .app uses the same way of defining resources (the data attribute). Some iOS simulator tests are failing due to missing resources, so let's sync them all. BUG=webrtc:5949 NOTRY=True Review-Url: https://codereview.webrtc.org/2277753003 Cr-Commit-Position: refs/heads/master@{#13898} --- webrtc/BUILD.gn | 4 +++- webrtc/common_video/BUILD.gn | 7 +++---- webrtc/media/BUILD.gn | 6 +++--- webrtc/modules/BUILD.gn | 7 +++---- webrtc/modules/audio_coding/BUILD.gn | 6 +----- webrtc/test/BUILD.gn | 8 ++++---- webrtc/tools/BUILD.gn | 6 +++--- 7 files changed, 20 insertions(+), 24 deletions(-) diff --git a/webrtc/BUILD.gn b/webrtc/BUILD.gn index 74167e2396..530c5d4e3c 100644 --- a/webrtc/BUILD.gn +++ b/webrtc/BUILD.gn @@ -700,11 +700,13 @@ if (rtc_include_tests) { } if (is_android) { deps += [ "//testing/android/native_test:native_test_native_code" ] + shard_timeout = 900 + } + if (is_android || is_ios) { data = [ "//resources/foreman_cif_short.yuv", "//resources/voice_engine/audio_long16.pcm", ] - shard_timeout = 900 } } diff --git a/webrtc/common_video/BUILD.gn b/webrtc/common_video/BUILD.gn index 14cbc7d3ff..7c03ffdb40 100644 --- a/webrtc/common_video/BUILD.gn +++ b/webrtc/common_video/BUILD.gn @@ -118,14 +118,13 @@ if (rtc_include_tests) { if (is_android) { deps += [ "//testing/android/native_test:native_test_support" ] + shard_timeout = 900 + } - # This needs to be kept in sync with the .isolate file. - # TODO(kjellander); Move this to android_assets targets instead. + if (is_android || is_ios) { data = [ "//resources/foreman_cif.yuv", ] - - shard_timeout = 900 } } } diff --git a/webrtc/media/BUILD.gn b/webrtc/media/BUILD.gn index a95ab23d9e..d0453c7db8 100644 --- a/webrtc/media/BUILD.gn +++ b/webrtc/media/BUILD.gn @@ -340,9 +340,9 @@ if (rtc_include_tests) { if (is_android) { deps += [ "//testing/android/native_test:native_test_support" ] - - # This needs to be kept in sync with the rtc_media_unittests.isolate file. - # TODO(kjellander); Move this to android_assets targets instead. + shard_timeout = 900 + } + if (is_android || is_ios) { data = [ "//resources/media/captured-320x240-2s-48.frames", "//resources/media/faces.1280x720_P420.yuv", diff --git a/webrtc/modules/BUILD.gn b/webrtc/modules/BUILD.gn index 9244a67149..c04f00c49b 100644 --- a/webrtc/modules/BUILD.gn +++ b/webrtc/modules/BUILD.gn @@ -506,9 +506,10 @@ if (rtc_include_tests) { "audio_device/android/ensure_initialized.cc", "audio_device/android/ensure_initialized.h", ] + shard_timeout = 900 + } - # This needs to be kept in sync with the .isolate file. - # TODO(kjellander); Move this to android_assets targets instead. + if (is_android || is_ios) { data = [ "//data/audio_processing/output_data_fixed.pb", "//data/audio_processing/output_data_float.pb", @@ -611,8 +612,6 @@ if (rtc_include_tests) { "//resources/verizon4g-downlink.rx", "//resources/verizon4g-uplink.rx", ] - - shard_timeout = 900 } if (is_ios) { diff --git a/webrtc/modules/audio_coding/BUILD.gn b/webrtc/modules/audio_coding/BUILD.gn index 1b14f02785..0b680ce5af 100644 --- a/webrtc/modules/audio_coding/BUILD.gn +++ b/webrtc/modules/audio_coding/BUILD.gn @@ -1033,13 +1033,9 @@ if (rtc_include_tests) { if (is_android) { deps += [ "//testing/android/native_test:native_test_native_code" ] shard_timeout = 900 - - data = [ - "//resources/audio_coding/testfile32kHz.pcm", - ] } - if (is_ios) { + if (is_android || is_ios) { data = [ "//resources/audio_coding/testfile32kHz.pcm", ] diff --git a/webrtc/test/BUILD.gn b/webrtc/test/BUILD.gn index 91471039a6..cf23282253 100644 --- a/webrtc/test/BUILD.gn +++ b/webrtc/test/BUILD.gn @@ -314,9 +314,10 @@ test("test_support_unittests") { if (is_android) { deps += [ "//testing/android/native_test:native_test_support" ] + shard_timeout = 900 + } - # This needs to be kept in sync with the test_support_unittests.isolate file. - # TODO(kjellander); Move this to android_assets targets instead. + if (is_android || is_ios) { data = [ "//resources/foreman_cif_short.yuv", "//resources/video_coding/frame-ethernet-ii.pcap", @@ -326,9 +327,8 @@ test("test_support_unittests") { "//resources/video_coding/ssrcs-2.pcap", "//resources/video_coding/ssrcs-3.pcap", ] - - shard_timeout = 900 } + deps += [ ":channel_transport", ":test_common", diff --git a/webrtc/tools/BUILD.gn b/webrtc/tools/BUILD.gn index d551483008..35e4fb3694 100644 --- a/webrtc/tools/BUILD.gn +++ b/webrtc/tools/BUILD.gn @@ -350,12 +350,12 @@ if (rtc_include_tests) { if (is_android) { deps += [ "//testing/android/native_test:native_test_support" ] - + shard_timeout = 900 + } + if (is_android || is_ios) { data = [ "//resources/foreman_cif.yuv", ] - - shard_timeout = 900 } }