OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 3038 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3049 | 3049 |
3050 constraints.AddOptional( | 3050 constraints.AddOptional( |
3051 webrtc::MediaConstraintsInterface::kEnableVideoSuspendBelowMinBitrate, | 3051 webrtc::MediaConstraintsInterface::kEnableVideoSuspendBelowMinBitrate, |
3052 true); | 3052 true); |
3053 const cricket::MediaConfig media_config = | 3053 const cricket::MediaConfig media_config = |
3054 TestCreatePeerConnection(config, &constraints); | 3054 TestCreatePeerConnection(config, &constraints); |
3055 | 3055 |
3056 EXPECT_TRUE(media_config.video.suspend_below_min_bitrate); | 3056 EXPECT_TRUE(media_config.video.suspend_below_min_bitrate); |
3057 } | 3057 } |
3058 | 3058 |
| 3059 /* |
| 3060 * |
3059 // The following tests verify that session options are created correctly. | 3061 // The following tests verify that session options are created correctly. |
3060 // TODO(deadbeef): Convert these tests to be more end-to-end. Instead of | 3062 // TODO(deadbeef): Convert these tests to be more end-to-end. Instead of |
3061 // "verify options are converted correctly", should be "pass options into | 3063 // "verify options are converted correctly", should be "pass options into |
3062 // CreateOffer and verify the correct offer is produced." | 3064 // CreateOffer and verify the correct offer is produced." |
3063 | 3065 |
3064 TEST(CreateSessionOptionsTest, GetOptionsForOfferWithInvalidAudioOption) { | 3066 TEST(CreateSessionOptionsTest, GetOptionsForOfferWithInvalidAudioOption) { |
3065 RTCOfferAnswerOptions rtc_options; | 3067 RTCOfferAnswerOptions rtc_options; |
3066 rtc_options.offer_to_receive_audio = RTCOfferAnswerOptions::kUndefined - 1; | 3068 rtc_options.offer_to_receive_audio = RTCOfferAnswerOptions::kUndefined - 1; |
3067 | 3069 |
3068 cricket::MediaSessionOptions options; | 3070 cricket::MediaSessionOptions options; |
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3219 FakeConstraints updated_answer_c; | 3221 FakeConstraints updated_answer_c; |
3220 answer_c.SetMandatoryReceiveAudio(false); | 3222 answer_c.SetMandatoryReceiveAudio(false); |
3221 answer_c.SetMandatoryReceiveVideo(false); | 3223 answer_c.SetMandatoryReceiveVideo(false); |
3222 | 3224 |
3223 cricket::MediaSessionOptions updated_answer_options; | 3225 cricket::MediaSessionOptions updated_answer_options; |
3224 EXPECT_TRUE( | 3226 EXPECT_TRUE( |
3225 ParseConstraintsForAnswer(&updated_answer_c, &updated_answer_options)); | 3227 ParseConstraintsForAnswer(&updated_answer_c, &updated_answer_options)); |
3226 EXPECT_TRUE(updated_answer_options.has_audio()); | 3228 EXPECT_TRUE(updated_answer_options.has_audio()); |
3227 EXPECT_TRUE(updated_answer_options.has_video()); | 3229 EXPECT_TRUE(updated_answer_options.has_video()); |
3228 } | 3230 } |
| 3231 */ |
3229 | 3232 |
3230 TEST(RtcErrorTest, OstreamOperator) { | 3233 TEST(RtcErrorTest, OstreamOperator) { |
3231 std::ostringstream oss; | 3234 std::ostringstream oss; |
3232 oss << webrtc::RtcError::NONE << ' ' | 3235 oss << webrtc::RtcError::NONE << ' ' |
3233 << webrtc::RtcError::INVALID_PARAMETER << ' ' | 3236 << webrtc::RtcError::INVALID_PARAMETER << ' ' |
3234 << webrtc::RtcError::INTERNAL_ERROR; | 3237 << webrtc::RtcError::INTERNAL_ERROR; |
3235 EXPECT_EQ("NONE INVALID_PARAMETER INTERNAL_ERROR", oss.str()); | 3238 EXPECT_EQ("NONE INVALID_PARAMETER INTERNAL_ERROR", oss.str()); |
3236 } | 3239 } |
OLD | NEW |