summaryrefslogtreecommitdiffstats
path: root/third_party/libwebrtc/pc/peer_connection_integrationtest.cc
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-15 03:34:50 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-15 03:34:50 +0000
commitdef92d1b8e9d373e2f6f27c366d578d97d8960c6 (patch)
tree2ef34b9ad8bb9a9220e05d60352558b15f513894 /third_party/libwebrtc/pc/peer_connection_integrationtest.cc
parentAdding debian version 125.0.3-1. (diff)
downloadfirefox-def92d1b8e9d373e2f6f27c366d578d97d8960c6.tar.xz
firefox-def92d1b8e9d373e2f6f27c366d578d97d8960c6.zip
Merging upstream version 126.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'third_party/libwebrtc/pc/peer_connection_integrationtest.cc')
-rw-r--r--third_party/libwebrtc/pc/peer_connection_integrationtest.cc24
1 files changed, 12 insertions, 12 deletions
diff --git a/third_party/libwebrtc/pc/peer_connection_integrationtest.cc b/third_party/libwebrtc/pc/peer_connection_integrationtest.cc
index bfff86ee93..c960a36b5e 100644
--- a/third_party/libwebrtc/pc/peer_connection_integrationtest.cc
+++ b/third_party/libwebrtc/pc/peer_connection_integrationtest.cc
@@ -1356,15 +1356,15 @@ TEST_P(PeerConnectionIntegrationTest, NewGetStatsManyAudioAndManyVideoStreams) {
ASSERT_EQ(outbound_stream_stats.size(), 4u);
std::vector<std::string> outbound_track_ids;
for (const auto& stat : outbound_stream_stats) {
- ASSERT_TRUE(stat->bytes_sent.is_defined());
+ ASSERT_TRUE(stat->bytes_sent.has_value());
EXPECT_LT(0u, *stat->bytes_sent);
if (*stat->kind == "video") {
- ASSERT_TRUE(stat->key_frames_encoded.is_defined());
+ ASSERT_TRUE(stat->key_frames_encoded.has_value());
EXPECT_GT(*stat->key_frames_encoded, 0u);
- ASSERT_TRUE(stat->frames_encoded.is_defined());
+ ASSERT_TRUE(stat->frames_encoded.has_value());
EXPECT_GE(*stat->frames_encoded, *stat->key_frames_encoded);
}
- ASSERT_TRUE(stat->media_source_id.is_defined());
+ ASSERT_TRUE(stat->media_source_id.has_value());
const RTCMediaSourceStats* media_source =
static_cast<const RTCMediaSourceStats*>(
caller_report->Get(*stat->media_source_id));
@@ -1381,12 +1381,12 @@ TEST_P(PeerConnectionIntegrationTest, NewGetStatsManyAudioAndManyVideoStreams) {
ASSERT_EQ(4u, inbound_stream_stats.size());
std::vector<std::string> inbound_track_ids;
for (const auto& stat : inbound_stream_stats) {
- ASSERT_TRUE(stat->bytes_received.is_defined());
+ ASSERT_TRUE(stat->bytes_received.has_value());
EXPECT_LT(0u, *stat->bytes_received);
if (*stat->kind == "video") {
- ASSERT_TRUE(stat->key_frames_decoded.is_defined());
+ ASSERT_TRUE(stat->key_frames_decoded.has_value());
EXPECT_GT(*stat->key_frames_decoded, 0u);
- ASSERT_TRUE(stat->frames_decoded.is_defined());
+ ASSERT_TRUE(stat->frames_decoded.has_value());
EXPECT_GE(*stat->frames_decoded, *stat->key_frames_decoded);
}
inbound_track_ids.push_back(*stat->track_identifier);
@@ -1417,7 +1417,7 @@ TEST_P(PeerConnectionIntegrationTest,
auto inbound_stream_stats =
report->GetStatsOfType<RTCInboundRtpStreamStats>();
ASSERT_EQ(1U, inbound_stream_stats.size());
- ASSERT_TRUE(inbound_stream_stats[0]->bytes_received.is_defined());
+ ASSERT_TRUE(inbound_stream_stats[0]->bytes_received.has_value());
ASSERT_GT(*inbound_stream_stats[0]->bytes_received, 0U);
}
@@ -1464,7 +1464,7 @@ TEST_P(PeerConnectionIntegrationTest,
auto inbound_rtps = report->GetStatsOfType<RTCInboundRtpStreamStats>();
auto index = FindFirstMediaStatsIndexByKind("audio", inbound_rtps);
ASSERT_GE(index, 0);
- EXPECT_TRUE(inbound_rtps[index]->audio_level.is_defined());
+ EXPECT_TRUE(inbound_rtps[index]->audio_level.has_value());
}
// Test that DTLS 1.0 is used if both sides only support DTLS 1.0.
@@ -2952,7 +2952,7 @@ double GetAudioEnergyStat(PeerConnectionIntegrationWrapper* pc) {
auto inbound_rtps = report->GetStatsOfType<RTCInboundRtpStreamStats>();
RTC_CHECK(!inbound_rtps.empty());
auto* inbound_rtp = inbound_rtps[0];
- if (!inbound_rtp->total_audio_energy.is_defined()) {
+ if (!inbound_rtp->total_audio_energy.has_value()) {
return 0.0;
}
return *inbound_rtp->total_audio_energy;
@@ -3776,7 +3776,7 @@ int NacksReceivedCount(PeerConnectionIntegrationWrapper& pc) {
ADD_FAILURE();
return 0;
}
- if (!sender_stats[0]->nack_count.is_defined()) {
+ if (!sender_stats[0]->nack_count.has_value()) {
return 0;
}
return *sender_stats[0]->nack_count;
@@ -3789,7 +3789,7 @@ int NacksSentCount(PeerConnectionIntegrationWrapper& pc) {
ADD_FAILURE();
return 0;
}
- if (!receiver_stats[0]->nack_count.is_defined()) {
+ if (!receiver_stats[0]->nack_count.has_value()) {
return 0;
}
return *receiver_stats[0]->nack_count;