diff --git a/modules/bitrate_controller/send_side_bandwidth_estimation.cc b/modules/bitrate_controller/send_side_bandwidth_estimation.cc index 58028012c9..86ee24abeb 100644 --- a/modules/bitrate_controller/send_side_bandwidth_estimation.cc +++ b/modules/bitrate_controller/send_side_bandwidth_estimation.cc @@ -280,7 +280,7 @@ void SendSideBandwidthEstimation::SetBitrates( void SendSideBandwidthEstimation::SetSendBitrate(DataRate bitrate, Timestamp at_time) { - RTC_DCHECK(bitrate > DataRate::Zero()); + RTC_DCHECK_GT(bitrate, DataRate::Zero()); // Reset to avoid being capped by the estimate. delay_based_bitrate_ = DataRate::Zero(); if (loss_based_bandwidth_estimation_.Enabled()) { diff --git a/modules/video_coding/receiver_unittest.cc b/modules/video_coding/receiver_unittest.cc index ae322f2df9..563116676f 100644 --- a/modules/video_coding/receiver_unittest.cc +++ b/modules/video_coding/receiver_unittest.cc @@ -265,7 +265,7 @@ class SimulatedClockWithFrames : public SimulatedClock { bool frame_injected = false; while (!timestamps_.empty() && timestamps_.front().arrive_time <= end_time) { - RTC_DCHECK(timestamps_.front().arrive_time >= start_time); + RTC_DCHECK_GE(timestamps_.front().arrive_time, start_time); SimulatedClock::AdvanceTimeMicroseconds(timestamps_.front().arrive_time - TimeInMicroseconds()); @@ -293,7 +293,7 @@ class SimulatedClockWithFrames : public SimulatedClock { size_t size) { int64_t previous_arrive_timestamp = 0; for (size_t i = 0; i < size; i++) { - RTC_CHECK(arrive_timestamps[i] >= previous_arrive_timestamp); + RTC_CHECK_GE(arrive_timestamps[i], previous_arrive_timestamp); timestamps_.push(TimestampPair(arrive_timestamps[i] * 1000, render_timestamps[i] * 1000)); previous_arrive_timestamp = arrive_timestamps[i]; diff --git a/test/scenario/scenario.cc b/test/scenario/scenario.cc index f4c4b92fcd..ff0cfe536e 100644 --- a/test/scenario/scenario.cc +++ b/test/scenario/scenario.cc @@ -312,7 +312,7 @@ void Scenario::Every(TimeDelta interval, std::function function) { } void Scenario::At(TimeDelta offset, std::function function) { - RTC_DCHECK_GT(offset.ms(), TimeSinceStart().ms()); + RTC_DCHECK_GT(offset, TimeSinceStart()); task_queue_.PostDelayedTask(function, TimeUntilTarget(offset).ms()); } diff --git a/test/scenario/video_stream.cc b/test/scenario/video_stream.cc index d1493b2bb5..f7d26cebd1 100644 --- a/test/scenario/video_stream.cc +++ b/test/scenario/video_stream.cc @@ -258,7 +258,7 @@ std::unique_ptr CreateImageSlideGenerator( if (slides.images.crop.width || slides.images.crop.height) { TimeDelta pause_duration = slides.change_interval - slides.images.crop.scroll_duration; - RTC_CHECK(pause_duration >= TimeDelta::Zero()); + RTC_CHECK_GE(pause_duration, TimeDelta::Zero()); int crop_width = slides.images.crop.width.value_or(slides.images.width); int crop_height = slides.images.crop.height.value_or(slides.images.height); RTC_CHECK_LE(crop_width, slides.images.width); diff --git a/test/time_controller/simulated_time_controller.cc b/test/time_controller/simulated_time_controller.cc index ba5e162cf0..a592474a2b 100644 --- a/test/time_controller/simulated_time_controller.cc +++ b/test/time_controller/simulated_time_controller.cc @@ -382,7 +382,7 @@ Timestamp SimulatedTimeControllerImpl::NextRunTime() const { void SimulatedTimeControllerImpl::AdvanceTime(Timestamp target_time) { rtc::CritScope time_lock(&time_lock_); - RTC_DCHECK(target_time >= current_time_); + RTC_DCHECK_GE(target_time, current_time_); current_time_ = target_time; } diff --git a/video/video_stream_encoder.cc b/video/video_stream_encoder.cc index 1cd8c92b30..9c184bad42 100644 --- a/video/video_stream_encoder.cc +++ b/video/video_stream_encoder.cc @@ -1516,7 +1516,7 @@ void VideoStreamEncoder::OnBitrateUpdated(DataRate target_bitrate, DataRate link_allocation, uint8_t fraction_lost, int64_t round_trip_time_ms) { - RTC_DCHECK(link_allocation >= target_bitrate); + RTC_DCHECK_GE(link_allocation, target_bitrate); if (!encoder_queue_.IsCurrent()) { encoder_queue_.PostTask([this, target_bitrate, link_allocation, fraction_lost, round_trip_time_ms] {