Index: media/filters/frame_processor_unittest.cc |
diff --git a/media/filters/frame_processor_unittest.cc b/media/filters/frame_processor_unittest.cc |
index 39a689e695772742cd0ac6629e7b8143f37161a3..ed4e715941e64293486820941d95564d8a425c4a 100644 |
--- a/media/filters/frame_processor_unittest.cc |
+++ b/media/filters/frame_processor_unittest.cc |
@@ -740,6 +740,23 @@ TEST_P(FrameProcessorTest, PartialAppendWindowFilterNoNewMediaSegment) { |
CheckReadsThenReadStalls(video_.get(), "0 10"); |
} |
+TEST_F(FrameProcessorTest, AudioOnly_SequenceModeContinuityAcrossReset) { |
+ InSequence s; |
+ AddTestTracks(HAS_AUDIO); |
+ new_media_segment_ = true; |
+ frame_processor_->SetSequenceMode(true); |
+ EXPECT_CALL(callbacks_, PossibleDurationIncrease(frame_duration_)); |
+ ProcessFrames("0K", ""); |
+ frame_processor_->Reset(); |
+ EXPECT_CALL(callbacks_, PossibleDurationIncrease(frame_duration_ * 2)); |
+ ProcessFrames("100K", ""); |
+ |
+ EXPECT_EQ(frame_duration_ * -9, timestamp_offset_); |
+ EXPECT_FALSE(new_media_segment_); |
+ CheckExpectedRangesByTimestamp(audio_.get(), "{ [0,20) }"); |
+ CheckReadsThenReadStalls(audio_.get(), "0 10:100"); |
+} |
+ |
INSTANTIATE_TEST_CASE_P(SequenceMode, FrameProcessorTest, Values(true)); |
INSTANTIATE_TEST_CASE_P(SegmentsMode, FrameProcessorTest, Values(false)); |