Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Unified Diff: webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.h

Issue 2126793002: Reset InterArrival if arrival time clock makes a jump. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fix a few test issues. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.h
diff --git a/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.h b/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.h
index b4bff670e75529e3a8fb36bcf17bb96ce30c4301..4822d40e8bb2f79220a1fddfffc67903733dedf3 100644
--- a/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.h
+++ b/webrtc/modules/remote_bitrate_estimator/remote_bitrate_estimator_unittest_helper.h
@@ -79,7 +79,7 @@ class RtpStream {
int64_t GenerateFrame(int64_t time_now_us, PacketList* packets);
// The send-side time when the next frame can be generated.
- double next_rtp_time() const;
+ int64_t next_rtp_time() const;
// Generates an RTCP packet.
RtcpPacket* Rtcp(int64_t time_now_us);
@@ -112,7 +112,7 @@ class StreamGenerator {
public:
typedef std::list<RtpStream::RtcpPacket*> RtcpList;
- StreamGenerator(int capacity, double time_now);
+ StreamGenerator(int capacity, int64_t time_now);
~StreamGenerator();
@@ -203,15 +203,16 @@ class RemoteBitrateEstimatorTest : public ::testing::Test {
void RateIncreaseRtpTimestampsTestHelper(int expected_iterations);
void CapacityDropTestHelper(int number_of_streams,
bool wrap_time_stamp,
- uint32_t expected_bitrate_drop_delta);
+ uint32_t expected_bitrate_drop_delta,
+ int64_t receiver_clock_offset_change_ms);
static const uint32_t kDefaultSsrc;
- static const int kArrivalTimeClockOffsetMs = 60000;
SimulatedClock clock_; // Time at the receiver.
std::unique_ptr<testing::TestBitrateObserver> bitrate_observer_;
std::unique_ptr<RemoteBitrateEstimator> bitrate_estimator_;
std::unique_ptr<testing::StreamGenerator> stream_generator_;
+ int64_t arrival_time_offset_ms_;
RTC_DISALLOW_COPY_AND_ASSIGN(RemoteBitrateEstimatorTest);
};

Powered by Google App Engine
This is Rietveld 408576698