objc wrapper for PeerConnection::SetBitrate
BUG=webrtc:7395
Review-Url: https://codereview.webrtc.org/2877933004
Cr-Commit-Position: refs/heads/master@{#19294}
diff --git a/webrtc/sdk/objc/Framework/UnitTests/RTCPeerConnectionTest.mm b/webrtc/sdk/objc/Framework/UnitTests/RTCPeerConnectionTest.mm
index 63b21bf..429962d 100644
--- a/webrtc/sdk/objc/Framework/UnitTests/RTCPeerConnectionTest.mm
+++ b/webrtc/sdk/objc/Framework/UnitTests/RTCPeerConnectionTest.mm
@@ -59,7 +59,15 @@
RTCPeerConnection *peerConnection =
[factory peerConnectionWithConfiguration:config constraints:contraints delegate:nil];
newConfig = peerConnection.configuration;
+
+ EXPECT_TRUE([peerConnection setBitrateToMin:[NSNumber numberWithInt:100000]
+ toCurrent:[NSNumber numberWithInt:5000000]
+ toMax:[NSNumber numberWithInt:500000000]]);
+ EXPECT_FALSE([peerConnection setBitrateToMin:[NSNumber numberWithInt:2]
+ toCurrent:[NSNumber numberWithInt:1]
+ toMax:nullptr]);
}
+
EXPECT_EQ([config.iceServers count], [newConfig.iceServers count]);
RTCIceServer *newServer = newConfig.iceServers[0];
RTCIceServer *origServer = config.iceServers[0];