henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 1 | # |
| 2 | # libjingle |
| 3 | # Copyright 2012, Google Inc. |
| 4 | # |
| 5 | # Redistribution and use in source and binary forms, with or without |
| 6 | # modification, are permitted provided that the following conditions are met: |
| 7 | # |
| 8 | # 1. Redistributions of source code must retain the above copyright notice, |
| 9 | # this list of conditions and the following disclaimer. |
| 10 | # 2. Redistributions in binary form must reproduce the above copyright notice, |
| 11 | # this list of conditions and the following disclaimer in the documentation |
| 12 | # and/or other materials provided with the distribution. |
| 13 | # 3. The name of the author may not be used to endorse or promote products |
| 14 | # derived from this software without specific prior written permission. |
| 15 | # |
| 16 | # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED |
| 17 | # WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
| 18 | # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO |
| 19 | # EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
| 20 | # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, |
| 21 | # PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; |
| 22 | # OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, |
| 23 | # WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR |
| 24 | # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF |
| 25 | # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 26 | # |
| 27 | |
| 28 | { |
| 29 | 'includes': ['build/common.gypi'], |
| 30 | 'targets': [ |
| 31 | { |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 32 | 'target_name': 'libjingle_unittest_main', |
| 33 | 'type': 'static_library', |
| 34 | 'dependencies': [ |
| 35 | '<(DEPTH)/third_party/libyuv/libyuv.gyp:libyuv', |
henrike@webrtc.org | 18ce94c | 2014-09-10 17:28:19 +0000 | [diff] [blame] | 36 | '<(webrtc_root)/base/base_tests.gyp:rtc_base_tests_utils', |
buildbot@webrtc.org | 82a3f3c | 2014-07-08 18:18:55 +0000 | [diff] [blame] | 37 | '<@(libjingle_tests_additional_deps)', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 38 | ], |
| 39 | 'direct_dependent_settings': { |
| 40 | 'include_dirs': [ |
| 41 | '<(DEPTH)/third_party/libyuv/include', |
buildbot@webrtc.org | 2a86ce2 | 2014-07-29 17:36:52 +0000 | [diff] [blame] | 42 | '<(DEPTH)/testing/gtest/include', |
| 43 | '<(DEPTH)/testing/gtest', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 44 | ], |
| 45 | }, |
buildbot@webrtc.org | 2a86ce2 | 2014-07-29 17:36:52 +0000 | [diff] [blame] | 46 | 'include_dirs': [ |
| 47 | '<(DEPTH)/testing/gtest/include', |
| 48 | '<(DEPTH)/testing/gtest', |
| 49 | ], |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 50 | 'sources': [ |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 51 | 'media/base/fakecapturemanager.h', |
| 52 | 'media/base/fakemediaengine.h', |
| 53 | 'media/base/fakemediaprocessor.h', |
| 54 | 'media/base/fakenetworkinterface.h', |
| 55 | 'media/base/fakertp.h', |
| 56 | 'media/base/fakevideocapturer.h', |
| 57 | 'media/base/fakevideorenderer.h', |
| 58 | 'media/base/nullvideoframe.h', |
| 59 | 'media/base/nullvideorenderer.h', |
| 60 | 'media/base/testutils.cc', |
| 61 | 'media/base/testutils.h', |
| 62 | 'media/devices/fakedevicemanager.h', |
wu@webrtc.org | cfd6247 | 2013-12-11 18:25:07 +0000 | [diff] [blame] | 63 | 'media/webrtc/dummyinstantiation.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 64 | 'media/webrtc/fakewebrtccommon.h', |
| 65 | 'media/webrtc/fakewebrtcdeviceinfo.h', |
| 66 | 'media/webrtc/fakewebrtcvcmfactory.h', |
| 67 | 'media/webrtc/fakewebrtcvideocapturemodule.h', |
| 68 | 'media/webrtc/fakewebrtcvideoengine.h', |
| 69 | 'media/webrtc/fakewebrtcvoiceengine.h', |
| 70 | ], |
| 71 | }, # target libjingle_unittest_main |
| 72 | { |
| 73 | 'target_name': 'libjingle_unittest', |
| 74 | 'type': 'executable', |
fischman@webrtc.org | aa06b85 | 2014-04-29 18:37:29 +0000 | [diff] [blame] | 75 | 'includes': [ 'build/ios_tests.gypi', ], |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 76 | 'dependencies': [ |
henrike@webrtc.org | 18ce94c | 2014-09-10 17:28:19 +0000 | [diff] [blame] | 77 | '<(webrtc_root)/base/base.gyp:rtc_base', |
| 78 | '<(webrtc_root)/base/base_tests.gyp:rtc_base_tests_utils', |
henrike@webrtc.org | a258a15 | 2014-09-15 08:13:36 +0000 | [diff] [blame] | 79 | '<(webrtc_root)/libjingle/xmllite/xmllite.gyp:rtc_xmllite', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 80 | 'libjingle.gyp:libjingle', |
| 81 | 'libjingle_unittest_main', |
| 82 | ], |
| 83 | 'sources': [ |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 84 | 'xmpp/fakexmppclient.h', |
| 85 | 'xmpp/hangoutpubsubclient_unittest.cc', |
| 86 | 'xmpp/jid_unittest.cc', |
| 87 | 'xmpp/mucroomconfigtask_unittest.cc', |
| 88 | 'xmpp/mucroomdiscoverytask_unittest.cc', |
| 89 | 'xmpp/mucroomlookuptask_unittest.cc', |
| 90 | 'xmpp/mucroomuniquehangoutidtask_unittest.cc', |
| 91 | 'xmpp/pingtask_unittest.cc', |
| 92 | 'xmpp/pubsubclient_unittest.cc', |
| 93 | 'xmpp/pubsubtasks_unittest.cc', |
| 94 | 'xmpp/util_unittest.cc', |
| 95 | 'xmpp/util_unittest.h', |
| 96 | 'xmpp/xmppengine_unittest.cc', |
| 97 | 'xmpp/xmpplogintask_unittest.cc', |
| 98 | 'xmpp/xmppstanzaparser_unittest.cc', |
| 99 | ], # sources |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 100 | }, # target libjingle_unittest |
| 101 | { |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 102 | 'target_name': 'libjingle_media_unittest', |
| 103 | 'type': 'executable', |
| 104 | 'dependencies': [ |
henrike@webrtc.org | 18ce94c | 2014-09-10 17:28:19 +0000 | [diff] [blame] | 105 | '<(webrtc_root)/base/base_tests.gyp:rtc_base_tests_utils', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 106 | 'libjingle.gyp:libjingle_media', |
| 107 | 'libjingle_unittest_main', |
| 108 | ], |
| 109 | # TODO(ronghuawu): Avoid the copies. |
| 110 | # https://code.google.com/p/libjingle/issues/detail?id=398 |
| 111 | 'copies': [ |
| 112 | { |
| 113 | 'destination': '<(DEPTH)/../talk/media/testdata', |
| 114 | 'files': [ |
| 115 | 'media/testdata/1.frame_plus_1.byte', |
| 116 | 'media/testdata/captured-320x240-2s-48.frames', |
| 117 | 'media/testdata/h264-svc-99-640x360.rtpdump', |
| 118 | 'media/testdata/video.rtpdump', |
| 119 | 'media/testdata/voice.rtpdump', |
| 120 | ], |
| 121 | }, |
| 122 | ], |
| 123 | 'sources': [ |
| 124 | # TODO(ronghuawu): Reenable this test. |
| 125 | # 'media/base/capturemanager_unittest.cc', |
| 126 | 'media/base/codec_unittest.cc', |
| 127 | 'media/base/filemediaengine_unittest.cc', |
| 128 | 'media/base/rtpdataengine_unittest.cc', |
| 129 | 'media/base/rtpdump_unittest.cc', |
| 130 | 'media/base/rtputils_unittest.cc', |
pbos@webrtc.org | 6149956 | 2014-07-17 08:51:46 +0000 | [diff] [blame] | 131 | 'media/base/streamparams_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 132 | 'media/base/testutils.cc', |
| 133 | 'media/base/testutils.h', |
buildbot@webrtc.org | 2a05536 | 2014-08-07 04:47:36 +0000 | [diff] [blame] | 134 | 'media/base/videoadapter_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 135 | 'media/base/videocapturer_unittest.cc', |
| 136 | 'media/base/videocommon_unittest.cc', |
| 137 | 'media/base/videoengine_unittest.h', |
| 138 | 'media/devices/dummydevicemanager_unittest.cc', |
| 139 | 'media/devices/filevideocapturer_unittest.cc', |
jiayl@webrtc.org | d19ccc1 | 2014-06-18 21:30:40 +0000 | [diff] [blame] | 140 | 'media/sctp/sctpdataengine_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 141 | 'media/webrtc/webrtcpassthroughrender_unittest.cc', |
| 142 | 'media/webrtc/webrtcvideocapturer_unittest.cc', |
thorcarpenter@google.com | 9289145 | 2014-09-05 16:34:13 +0000 | [diff] [blame] | 143 | 'media/base/videoframe_unittest.h', |
| 144 | 'media/webrtc/webrtcvideoframe_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 145 | |
| 146 | # Disabled because some tests fail. |
| 147 | # TODO(ronghuawu): Reenable these tests. |
| 148 | # 'media/devices/devicemanager_unittest.cc', |
wu@webrtc.org | f665ac8 | 2014-01-24 17:37:46 +0000 | [diff] [blame] | 149 | 'media/webrtc/webrtcvideoengine_unittest.cc', |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 150 | 'media/webrtc/webrtcvideoengine2_unittest.cc', |
pbos@webrtc.org | 1ef658d | 2014-06-10 08:53:05 +0000 | [diff] [blame] | 151 | 'media/webrtc/webrtcvideoengine2_unittest.h', |
wu@webrtc.org | f665ac8 | 2014-01-24 17:37:46 +0000 | [diff] [blame] | 152 | 'media/webrtc/webrtcvoiceengine_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 153 | ], |
| 154 | 'conditions': [ |
| 155 | ['OS=="win"', { |
thorcarpenter@google.com | 1a6b25e | 2014-09-19 17:54:00 +0000 | [diff] [blame] | 156 | 'dependencies': [ |
| 157 | '<(DEPTH)/net/third_party/nss/ssl.gyp:libssl', |
| 158 | '<(DEPTH)/third_party/nss/nss.gyp:nspr', |
| 159 | '<(DEPTH)/third_party/nss/nss.gyp:nss', |
| 160 | ], |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 161 | 'msvs_settings': { |
| 162 | 'VCLinkerTool': { |
| 163 | 'AdditionalDependencies': [ |
| 164 | # TODO(ronghuawu): Since we've included strmiids in |
| 165 | # libjingle_media target, we shouldn't need this here. |
| 166 | # Find out why it doesn't work without this. |
| 167 | 'strmiids.lib', |
| 168 | ], |
| 169 | }, |
| 170 | }, |
| 171 | }], |
jiayl@webrtc.org | 13a42bc | 2014-01-29 17:45:53 +0000 | [diff] [blame] | 172 | ['OS=="ios"', { |
| 173 | 'sources!': [ |
| 174 | 'media/sctp/sctpdataengine_unittest.cc', |
| 175 | ], |
| 176 | }], |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 177 | ], |
| 178 | }, # target libjingle_media_unittest |
| 179 | { |
| 180 | 'target_name': 'libjingle_p2p_unittest', |
| 181 | 'type': 'executable', |
| 182 | 'dependencies': [ |
| 183 | '<(DEPTH)/third_party/libsrtp/libsrtp.gyp:libsrtp', |
henrike@webrtc.org | 18ce94c | 2014-09-10 17:28:19 +0000 | [diff] [blame] | 184 | '<(webrtc_root)/base/base_tests.gyp:rtc_base_tests_utils', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 185 | 'libjingle.gyp:libjingle', |
| 186 | 'libjingle.gyp:libjingle_p2p', |
| 187 | 'libjingle_unittest_main', |
| 188 | ], |
| 189 | 'include_dirs': [ |
| 190 | '<(DEPTH)/third_party/libsrtp/srtp', |
| 191 | ], |
| 192 | 'sources': [ |
| 193 | 'p2p/base/dtlstransportchannel_unittest.cc', |
| 194 | 'p2p/base/fakesession.h', |
| 195 | 'p2p/base/p2ptransportchannel_unittest.cc', |
| 196 | 'p2p/base/port_unittest.cc', |
| 197 | 'p2p/base/portallocatorsessionproxy_unittest.cc', |
| 198 | 'p2p/base/pseudotcp_unittest.cc', |
| 199 | 'p2p/base/relayport_unittest.cc', |
| 200 | 'p2p/base/relayserver_unittest.cc', |
| 201 | 'p2p/base/session_unittest.cc', |
| 202 | 'p2p/base/stun_unittest.cc', |
| 203 | 'p2p/base/stunport_unittest.cc', |
| 204 | 'p2p/base/stunrequest_unittest.cc', |
| 205 | 'p2p/base/stunserver_unittest.cc', |
| 206 | 'p2p/base/testrelayserver.h', |
| 207 | 'p2p/base/teststunserver.h', |
| 208 | 'p2p/base/testturnserver.h', |
| 209 | 'p2p/base/transport_unittest.cc', |
| 210 | 'p2p/base/transportdescriptionfactory_unittest.cc', |
mallinath@webrtc.org | d5c92b8 | 2014-07-17 21:55:04 +0000 | [diff] [blame] | 211 | 'p2p/base/turnport_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 212 | 'p2p/client/connectivitychecker_unittest.cc', |
| 213 | 'p2p/client/fakeportallocator.h', |
| 214 | 'p2p/client/portallocator_unittest.cc', |
buildbot@webrtc.org | 907f45c | 2014-05-05 20:18:08 +0000 | [diff] [blame] | 215 | 'session/media/bundlefilter_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 216 | 'session/media/channel_unittest.cc', |
| 217 | 'session/media/channelmanager_unittest.cc', |
| 218 | 'session/media/currentspeakermonitor_unittest.cc', |
| 219 | 'session/media/mediarecorder_unittest.cc', |
| 220 | 'session/media/mediamessages_unittest.cc', |
| 221 | 'session/media/mediasession_unittest.cc', |
| 222 | 'session/media/mediasessionclient_unittest.cc', |
| 223 | 'session/media/rtcpmuxfilter_unittest.cc', |
| 224 | 'session/media/srtpfilter_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 225 | ], |
| 226 | 'conditions': [ |
| 227 | ['OS=="win"', { |
| 228 | 'msvs_settings': { |
| 229 | 'VCLinkerTool': { |
| 230 | 'AdditionalDependencies': [ |
| 231 | 'strmiids.lib', |
| 232 | ], |
| 233 | }, |
| 234 | }, |
| 235 | }], |
| 236 | ], |
| 237 | }, # target libjingle_p2p_unittest |
| 238 | { |
| 239 | 'target_name': 'libjingle_peerconnection_unittest', |
| 240 | 'type': 'executable', |
| 241 | 'dependencies': [ |
xians@webrtc.org | 890e587 | 2014-06-12 14:57:05 +0000 | [diff] [blame] | 242 | '<(DEPTH)/testing/gmock.gyp:gmock', |
henrike@webrtc.org | 18ce94c | 2014-09-10 17:28:19 +0000 | [diff] [blame] | 243 | '<(webrtc_root)/base/base_tests.gyp:rtc_base_tests_utils', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 244 | 'libjingle.gyp:libjingle', |
| 245 | 'libjingle.gyp:libjingle_p2p', |
| 246 | 'libjingle.gyp:libjingle_peerconnection', |
| 247 | 'libjingle_unittest_main', |
| 248 | ], |
xians@webrtc.org | 890e587 | 2014-06-12 14:57:05 +0000 | [diff] [blame] | 249 | 'direct_dependent_settings': { |
| 250 | 'include_dirs': [ |
| 251 | '<(DEPTH)/testing/gmock/include', |
| 252 | ], |
| 253 | }, |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 254 | 'sources': [ |
jiayl@webrtc.org | c1af570 | 2014-05-29 15:33:54 +0000 | [diff] [blame] | 255 | 'app/webrtc/datachannel_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 256 | 'app/webrtc/dtmfsender_unittest.cc', |
| 257 | 'app/webrtc/jsepsessiondescription_unittest.cc', |
| 258 | 'app/webrtc/localaudiosource_unittest.cc', |
xians@webrtc.org | 890e587 | 2014-06-12 14:57:05 +0000 | [diff] [blame] | 259 | 'app/webrtc/mediastream_unittest.cc', |
| 260 | 'app/webrtc/mediastreamhandler_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 261 | 'app/webrtc/mediastreamsignaling_unittest.cc', |
| 262 | 'app/webrtc/peerconnection_unittest.cc', |
wu@webrtc.org | 3db0458 | 2013-11-20 21:49:41 +0000 | [diff] [blame] | 263 | 'app/webrtc/peerconnectionendtoend_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 264 | 'app/webrtc/peerconnectionfactory_unittest.cc', |
| 265 | 'app/webrtc/peerconnectioninterface_unittest.cc', |
| 266 | # 'app/webrtc/peerconnectionproxy_unittest.cc', |
wu@webrtc.org | 4ba8b9e | 2013-09-19 05:49:50 +0000 | [diff] [blame] | 267 | 'app/webrtc/remotevideocapturer_unittest.cc', |
henrika@webrtc.org | 8485ec6 | 2014-01-14 10:00:58 +0000 | [diff] [blame] | 268 | 'app/webrtc/sctputils.cc', |
xians@webrtc.org | 890e587 | 2014-06-12 14:57:05 +0000 | [diff] [blame] | 269 | 'app/webrtc/statscollector_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 270 | 'app/webrtc/test/fakeaudiocapturemodule.cc', |
| 271 | 'app/webrtc/test/fakeaudiocapturemodule.h', |
| 272 | 'app/webrtc/test/fakeaudiocapturemodule_unittest.cc', |
| 273 | 'app/webrtc/test/fakeconstraints.h', |
wu@webrtc.org | d1f631d | 2013-10-30 05:18:12 +0000 | [diff] [blame] | 274 | 'app/webrtc/test/fakedatachannelprovider.h', |
wu@webrtc.org | 5aed3bb | 2013-08-10 07:18:04 +0000 | [diff] [blame] | 275 | 'app/webrtc/test/fakedtlsidentityservice.h', |
| 276 | 'app/webrtc/test/fakemediastreamsignaling.h', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 277 | 'app/webrtc/test/fakeperiodicvideocapturer.h', |
| 278 | 'app/webrtc/test/fakevideotrackrenderer.h', |
| 279 | 'app/webrtc/test/mockpeerconnectionobservers.h', |
wu@webrtc.org | 3db0458 | 2013-11-20 21:49:41 +0000 | [diff] [blame] | 280 | 'app/webrtc/test/peerconnectiontestwrapper.h', |
| 281 | 'app/webrtc/test/peerconnectiontestwrapper.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 282 | 'app/webrtc/test/testsdpstrings.h', |
wu@webrtc.org | 4ba8b9e | 2013-09-19 05:49:50 +0000 | [diff] [blame] | 283 | 'app/webrtc/videosource_unittest.cc', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 284 | 'app/webrtc/videotrack_unittest.cc', |
| 285 | 'app/webrtc/webrtcsdp_unittest.cc', |
| 286 | 'app/webrtc/webrtcsession_unittest.cc', |
| 287 | ], |
xians@webrtc.org | 890e587 | 2014-06-12 14:57:05 +0000 | [diff] [blame] | 288 | 'conditions': [ |
| 289 | ['OS=="android"', { |
| 290 | # We want gmock features that use tr1::tuple, but we currently |
| 291 | # don't support the variadic templates used by libstdc++'s |
| 292 | # implementation. gmock supports this scenario by providing its |
| 293 | # own implementation but we must opt in to it. |
| 294 | 'defines': [ |
| 295 | 'GTEST_USE_OWN_TR1_TUPLE=1', |
| 296 | # GTEST_USE_OWN_TR1_TUPLE only works if GTEST_HAS_TR1_TUPLE is set. |
| 297 | # gmock r625 made it so that GTEST_HAS_TR1_TUPLE is set to 0 |
| 298 | # automatically on android, so it has to be set explicitly here. |
| 299 | 'GTEST_HAS_TR1_TUPLE=1', |
| 300 | ], |
| 301 | }], |
| 302 | ], |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 303 | }, # target libjingle_peerconnection_unittest |
| 304 | ], |
| 305 | 'conditions': [ |
wu@webrtc.org | f99f101 | 2013-08-05 20:36:57 +0000 | [diff] [blame] | 306 | ['OS=="linux"', { |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 307 | 'targets': [ |
| 308 | { |
| 309 | 'target_name': 'libjingle_peerconnection_test_jar', |
| 310 | 'type': 'none', |
| 311 | 'actions': [ |
| 312 | { |
| 313 | 'variables': { |
| 314 | 'java_src_dir': 'app/webrtc/javatests/src', |
| 315 | 'java_files': [ |
| 316 | 'app/webrtc/javatests/src/org/webrtc/PeerConnectionTest.java', |
| 317 | ], |
| 318 | }, |
| 319 | 'action_name': 'create_jar', |
| 320 | 'inputs': [ |
| 321 | 'build/build_jar.sh', |
| 322 | '<@(java_files)', |
| 323 | '<(PRODUCT_DIR)/libjingle_peerconnection.jar', |
| 324 | '<(DEPTH)/third_party/junit/junit-4.11.jar', |
| 325 | ], |
| 326 | 'outputs': [ |
| 327 | '<(PRODUCT_DIR)/libjingle_peerconnection_test.jar', |
| 328 | ], |
| 329 | 'action': [ |
fischman@webrtc.org | 643b7b4 | 2013-07-30 18:11:07 +0000 | [diff] [blame] | 330 | 'build/build_jar.sh', '<(java_home)', '<@(_outputs)', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 331 | '<(INTERMEDIATE_DIR)', |
| 332 | '<(java_src_dir):<(PRODUCT_DIR)/libjingle_peerconnection.jar:<(DEPTH)/third_party/junit/junit-4.11.jar', |
| 333 | '<@(java_files)' |
| 334 | ], |
| 335 | }, |
| 336 | ], |
| 337 | }, |
| 338 | { |
| 339 | 'target_name': 'libjingle_peerconnection_java_unittest', |
| 340 | 'type': 'none', |
| 341 | 'actions': [ |
| 342 | { |
| 343 | 'action_name': 'copy libjingle_peerconnection_java_unittest', |
| 344 | 'inputs': [ |
| 345 | 'app/webrtc/javatests/libjingle_peerconnection_java_unittest.sh', |
| 346 | '<(PRODUCT_DIR)/libjingle_peerconnection_test_jar', |
| 347 | '<(DEPTH)/third_party/junit/junit-4.11.jar', |
| 348 | ], |
| 349 | 'outputs': [ |
| 350 | '<(PRODUCT_DIR)/libjingle_peerconnection_java_unittest', |
| 351 | ], |
| 352 | 'action': [ |
| 353 | 'bash', '-c', |
| 354 | 'rm -f <(PRODUCT_DIR)/libjingle_peerconnection_java_unittest && ' |
| 355 | 'sed -e "s@GYP_JAVA_HOME@<(java_home)@" ' |
| 356 | '< app/webrtc/javatests/libjingle_peerconnection_java_unittest.sh ' |
| 357 | '> <(PRODUCT_DIR)/libjingle_peerconnection_java_unittest && ' |
| 358 | 'cp <(DEPTH)/third_party/junit/junit-4.11.jar <(PRODUCT_DIR) && ' |
| 359 | 'chmod u+x <(PRODUCT_DIR)/libjingle_peerconnection_java_unittest' |
| 360 | ], |
| 361 | }, |
| 362 | ], |
| 363 | }, |
| 364 | ], |
| 365 | }], |
fischman@webrtc.org | d4428e6 | 2013-08-26 19:31:21 +0000 | [diff] [blame] | 366 | ['OS=="ios" or (OS=="mac" and target_arch!="ia32" and mac_sdk>="10.7")', { |
| 367 | # The >=10.7 above is required to make ARC link cleanly (e.g. as |
| 368 | # opposed to _compile_ cleanly, which the library under test |
| 369 | # does just fine on 10.6 too). |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 370 | 'targets': [ |
| 371 | { |
fischman@webrtc.org | aa06b85 | 2014-04-29 18:37:29 +0000 | [diff] [blame] | 372 | 'target_name': 'libjingle_peerconnection_objc_test', |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 373 | 'type': 'executable', |
fischman@webrtc.org | aa06b85 | 2014-04-29 18:37:29 +0000 | [diff] [blame] | 374 | 'includes': [ 'build/ios_tests.gypi', ], |
| 375 | 'dependencies': [ |
henrike@webrtc.org | 18ce94c | 2014-09-10 17:28:19 +0000 | [diff] [blame] | 376 | '<(webrtc_root)/base/base_tests.gyp:rtc_base_tests_utils', |
fischman@webrtc.org | aa06b85 | 2014-04-29 18:37:29 +0000 | [diff] [blame] | 377 | 'libjingle.gyp:libjingle_peerconnection_objc', |
| 378 | ], |
| 379 | 'sources': [ |
| 380 | 'app/webrtc/objctests/RTCPeerConnectionSyncObserver.h', |
| 381 | 'app/webrtc/objctests/RTCPeerConnectionSyncObserver.m', |
| 382 | 'app/webrtc/objctests/RTCPeerConnectionTest.mm', |
| 383 | 'app/webrtc/objctests/RTCSessionDescriptionSyncObserver.h', |
| 384 | 'app/webrtc/objctests/RTCSessionDescriptionSyncObserver.m', |
| 385 | # TODO(fischman): figure out if this works for ios or if it |
| 386 | # needs a GUI driver. |
| 387 | 'app/webrtc/objctests/mac/main.mm', |
| 388 | ], |
| 389 | 'FRAMEWORK_SEARCH_PATHS': [ |
| 390 | '$(inherited)', |
| 391 | '$(SDKROOT)/Developer/Library/Frameworks', |
| 392 | '$(DEVELOPER_LIBRARY_DIR)/Frameworks', |
| 393 | ], |
| 394 | |
| 395 | # TODO(fischman): there is duplication here with |
| 396 | # build/ios_tests.gypi, because for historical reasons the |
| 397 | # mac x64 bots expect this unittest to be in a bundle |
| 398 | # directory (.app). Once the bots don't expect this |
| 399 | # anymore, remove this duplication. |
| 400 | 'variables': { |
| 401 | 'infoplist_file': 'build/ios_test.plist', |
| 402 | }, |
kjellander@webrtc.org | cac39d7 | 2014-04-28 12:50:47 +0000 | [diff] [blame] | 403 | 'mac_bundle': 1, |
| 404 | 'mac_bundle_resources': [ |
| 405 | '<(infoplist_file)', |
| 406 | ], |
| 407 | # The plist is listed above so that it appears in XCode's file list, |
| 408 | # but we don't actually want to bundle it. |
| 409 | 'mac_bundle_resources!': [ |
| 410 | '<(infoplist_file)', |
| 411 | ], |
| 412 | 'xcode_settings': { |
| 413 | 'CLANG_ENABLE_OBJC_ARC': 'YES', |
tkchin@webrtc.org | a00076b | 2014-04-30 18:32:33 +0000 | [diff] [blame] | 414 | # common.gypi enables this for mac but we want this to be disabled |
| 415 | # like it is for ios. |
| 416 | 'CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS': 'NO', |
kjellander@webrtc.org | cac39d7 | 2014-04-28 12:50:47 +0000 | [diff] [blame] | 417 | 'INFOPLIST_FILE': '<(infoplist_file)', |
| 418 | }, |
tkchin@webrtc.org | a00076b | 2014-04-30 18:32:33 +0000 | [diff] [blame] | 419 | 'conditions': [ |
| 420 | ['OS=="mac"', { |
| 421 | 'xcode_settings': { |
| 422 | # Need to build against 10.7 framework for full ARC support |
| 423 | # on OSX. |
| 424 | 'MACOSX_DEPLOYMENT_TARGET' : '10.7', |
| 425 | }, |
| 426 | }], |
| 427 | ], |
fischman@webrtc.org | d4428e6 | 2013-08-26 19:31:21 +0000 | [diff] [blame] | 428 | }, # target libjingle_peerconnection_objc_test |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 429 | ], |
| 430 | }], |
kjellander@webrtc.org | 95d2b6d | 2013-10-04 19:31:27 +0000 | [diff] [blame] | 431 | ['test_isolation_mode != "noop"', { |
| 432 | 'targets': [ |
| 433 | { |
| 434 | 'target_name': 'libjingle_media_unittest_run', |
| 435 | 'type': 'none', |
| 436 | 'dependencies': [ |
| 437 | 'libjingle_media_unittest', |
| 438 | ], |
| 439 | 'includes': [ |
| 440 | 'build/isolate.gypi', |
| 441 | 'libjingle_media_unittest.isolate', |
| 442 | ], |
| 443 | 'sources': [ |
| 444 | 'libjingle_media_unittest.isolate', |
| 445 | ], |
| 446 | }, |
| 447 | { |
| 448 | 'target_name': 'libjingle_p2p_unittest_run', |
| 449 | 'type': 'none', |
| 450 | 'dependencies': [ |
| 451 | 'libjingle_p2p_unittest', |
| 452 | ], |
| 453 | 'includes': [ |
| 454 | 'build/isolate.gypi', |
| 455 | 'libjingle_p2p_unittest.isolate', |
| 456 | ], |
| 457 | 'sources': [ |
| 458 | 'libjingle_p2p_unittest.isolate', |
| 459 | ], |
| 460 | }, |
| 461 | { |
| 462 | 'target_name': 'libjingle_peerconnection_unittest_run', |
| 463 | 'type': 'none', |
| 464 | 'dependencies': [ |
| 465 | 'libjingle_peerconnection_unittest', |
| 466 | ], |
| 467 | 'includes': [ |
| 468 | 'build/isolate.gypi', |
| 469 | 'libjingle_peerconnection_unittest.isolate', |
| 470 | ], |
| 471 | 'sources': [ |
| 472 | 'libjingle_peerconnection_unittest.isolate', |
| 473 | ], |
| 474 | }, |
| 475 | { |
kjellander@webrtc.org | 95d2b6d | 2013-10-04 19:31:27 +0000 | [diff] [blame] | 476 | 'target_name': 'libjingle_unittest_run', |
| 477 | 'type': 'none', |
| 478 | 'dependencies': [ |
| 479 | 'libjingle_unittest', |
| 480 | ], |
| 481 | 'includes': [ |
| 482 | 'build/isolate.gypi', |
| 483 | 'libjingle_unittest.isolate', |
| 484 | ], |
| 485 | 'sources': [ |
| 486 | 'libjingle_unittest.isolate', |
| 487 | ], |
| 488 | }, |
| 489 | ], |
| 490 | }], |
henrike@webrtc.org | 0e118e7 | 2013-07-10 00:45:36 +0000 | [diff] [blame] | 491 | ], |
| 492 | } |