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

Unified Diff: media/base/pipeline_unittest.cc

Issue 9155003: Fix media timeline so that thumb never exceeds buffered data (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 11 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: media/base/pipeline_unittest.cc
diff --git a/media/base/pipeline_unittest.cc b/media/base/pipeline_unittest.cc
index 9980e2fa03c38fb2e85a630a81d5f060184be0c6..d6f9200a45a1eac74585e7563198a5b1881191bb 100644
--- a/media/base/pipeline_unittest.cc
+++ b/media/base/pipeline_unittest.cc
@@ -157,8 +157,8 @@ class PipelineTest : public ::testing::Test {
// Sets up expectations to allow the video renderer to initialize.
void InitializeVideoRenderer() {
EXPECT_CALL(*mocks_->video_renderer(),
- Initialize(mocks_->video_decoder(), _, _))
- .WillOnce(Invoke(&RunFilterCallback3));
+ Initialize(mocks_->video_decoder(), _, _, _))
+ .WillOnce(Invoke(&RunFilterCallback4));
EXPECT_CALL(*mocks_->video_renderer(), SetPlaybackRate(0.0f));
EXPECT_CALL(*mocks_->video_renderer(),
Seek(mocks_->demuxer()->GetStartTime(), _))
@@ -171,13 +171,13 @@ class PipelineTest : public ::testing::Test {
void InitializeAudioRenderer(bool disable_after_init_callback = false) {
if (disable_after_init_callback) {
EXPECT_CALL(*mocks_->audio_renderer(),
- Initialize(mocks_->audio_decoder(), _, _))
- .WillOnce(DoAll(Invoke(&RunFilterCallback3),
+ Initialize(mocks_->audio_decoder(), _, _, _))
+ .WillOnce(DoAll(Invoke(&RunFilterCallback4),
DisableAudioRenderer(mocks_->audio_renderer())));
} else {
EXPECT_CALL(*mocks_->audio_renderer(),
- Initialize(mocks_->audio_decoder(), _, _))
- .WillOnce(Invoke(&RunFilterCallback3));
+ Initialize(mocks_->audio_decoder(), _, _, _))
+ .WillOnce(Invoke(&RunFilterCallback4));
}
EXPECT_CALL(*mocks_->audio_renderer(), SetPlaybackRate(0.0f));
EXPECT_CALL(*mocks_->audio_renderer(), SetVolume(1.0f));
@@ -694,6 +694,7 @@ TEST_F(PipelineTest, AudioStreamShorterThanVideo) {
// Replace the clock so we can simulate wallclock time advancing w/o using
// Sleep().
pipeline_->SetClockForTesting(new Clock(&StaticClockFunction));
acolwell GONE FROM CHROMIUM 2012/01/24 18:13:59 I think if you move this before InitializeDemuxer(
vrk (LEFT CHROMIUM) 2012/01/25 00:09:32 Doing this actually made the test fail... because
+ static_cast<DemuxerHost*>(pipeline_)->SetDuration(duration);
EXPECT_EQ(0, host->GetTime().ToInternalValue());

Powered by Google App Engine
This is Rietveld 408576698