Using unit classes in BitrateAllocationUpdate struct.

This prepares for moving BitrateAllocationUpdate to API.

Bug: webrtc:9718
Change-Id: Ib2bcedb6b68fde33b6a2466f40829e86438aa973
Reviewed-on: https://webrtc-review.googlesource.com/c/111507
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25737}
This commit is contained in:
Sebastian Jansson
2018-11-21 19:13:07 +01:00
committed by Commit Bot
parent e4cccae299
commit 13e5903626
8 changed files with 65 additions and 45 deletions

View File

@ -474,10 +474,10 @@ TEST(AudioSendStreamTest, DoesNotPassHigherBitrateThanMaxBitrate) {
EXPECT_CALL(*helper.channel_send(),
SetBitrate(helper.config().max_bitrate_bps, _));
BitrateAllocationUpdate update;
update.bitrate_bps = helper.config().max_bitrate_bps + 5000;
update.fraction_loss = 0;
update.rtt = 50;
update.bwe_period_ms = 6000;
update.target_bitrate = DataRate::bps(helper.config().max_bitrate_bps + 5000);
update.packet_loss_ratio = 0;
update.round_trip_time = TimeDelta::ms(50);
update.bwe_period = TimeDelta::ms(6000);
send_stream->OnBitrateUpdated(update);
}
@ -486,10 +486,10 @@ TEST(AudioSendStreamTest, ProbingIntervalOnBitrateUpdated) {
auto send_stream = helper.CreateAudioSendStream();
EXPECT_CALL(*helper.channel_send(), SetBitrate(_, 5000));
BitrateAllocationUpdate update;
update.bitrate_bps = helper.config().max_bitrate_bps + 5000;
update.fraction_loss = 0;
update.rtt = 50;
update.bwe_period_ms = 5000;
update.target_bitrate = DataRate::bps(helper.config().max_bitrate_bps + 5000);
update.packet_loss_ratio = 0;
update.round_trip_time = TimeDelta::ms(50);
update.bwe_period = TimeDelta::ms(5000);
send_stream->OnBitrateUpdated(update);
}