Chromium Code Reviews| Index: webrtc/pc/peerconnectioninterface_unittest.cc |
| diff --git a/webrtc/pc/peerconnectioninterface_unittest.cc b/webrtc/pc/peerconnectioninterface_unittest.cc |
| index c2e6e186e459c67338fc783b5c760bf24b5a1671..ecd598dc1e1d2d238e48712fb56bdbe0537eb192 100644 |
| --- a/webrtc/pc/peerconnectioninterface_unittest.cc |
| +++ b/webrtc/pc/peerconnectioninterface_unittest.cc |
| @@ -2221,6 +2221,21 @@ TEST_F(PeerConnectionInterfaceTest, SetConfigurationChangesPruneTurnPortsFlag) { |
| EXPECT_TRUE(port_allocator_->prune_turn_ports()); |
| } |
| +// Test that the ice check interval can be changed. This does not verify that |
| +// the setting makes it all the way to P2PTransportChannel, as that would |
| +// require a very complex set of mocks. |
| +TEST_F(PeerConnectionInterfaceTest, SetConfigurationChangesIceCheckInterval) { |
| + PeerConnectionInterface::RTCConfiguration config; |
| + config.ice_check_min_interval = rtc::Optional<int>(); |
| + CreatePeerConnection(config, nullptr); |
| + config.ice_check_min_interval = rtc::Optional<int>(100); |
| + EXPECT_TRUE(pc_->SetConfiguration(config)); |
| + PeerConnectionInterface::RTCConfiguration new_config = |
| + pc_->GetConfiguration(); |
| + EXPECT_TRUE(new_config.ice_check_min_interval); |
|
Taylor Brandstetter
2017/02/03 23:56:17
nit: ASSERT_TRUE, since the next line will crash i
skvlad
2017/02/04 00:01:51
I'm now comparing it with rtc::Optional<int>(100).
|
| + EXPECT_EQ(*new_config.ice_check_min_interval, 100); |
| +} |
| + |
| // Test that when SetConfiguration changes both the pool size and other |
| // attributes, the pooled session is created with the updated attributes. |
| TEST_F(PeerConnectionInterfaceTest, |