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

Side by Side Diff: media/filters/pipeline_controller_unittest.cc

Issue 1978973002: Moves video frame callbacks from VideoFrameCompositor to Renderer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixes media_bit_reader_fuzzer link error Created 4 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "media/filters/pipeline_controller.h" 5 #include "media/filters/pipeline_controller.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 111
112 void OnSeeked(bool time_updated) { 112 void OnSeeked(bool time_updated) {
113 was_seeked_ = true; 113 was_seeked_ = true;
114 last_seeked_time_updated_ = time_updated; 114 last_seeked_time_updated_ = time_updated;
115 } 115 }
116 116
117 void OnSuspended() { was_suspended_ = true; } 117 void OnSuspended() { was_suspended_ = true; }
118 118
119 // Pipeline::Client overrides 119 // Pipeline::Client overrides
120 void OnError(PipelineStatus status) override { NOTREACHED(); } 120 void OnError(PipelineStatus status) override { NOTREACHED(); }
121 void OnEnded() override{}; 121 void OnEnded() override {}
122 void OnMetadata(PipelineMetadata metadata) override{}; 122 void OnMetadata(PipelineMetadata metadata) override {}
123 void OnBufferingStateChange(BufferingState state) override{}; 123 void OnBufferingStateChange(BufferingState state) override {}
124 void OnDurationChange() override{}; 124 void OnDurationChange() override {}
125 void OnAddTextTrack(const TextTrackConfig& config, 125 void OnAddTextTrack(const TextTrackConfig& config,
126 const AddTextTrackDoneCB& done_cb) override{}; 126 const AddTextTrackDoneCB& done_cb) override {}
127 void OnWaitingForDecryptionKey() override{}; 127 void OnWaitingForDecryptionKey() override {}
128 void OnVideoNaturalSizeChange(const gfx::Size& size) override {}
129 void OnVideoOpacityChange(bool opaque) override {}
128 130
129 base::MessageLoop message_loop_; 131 base::MessageLoop message_loop_;
130 132
131 NiceMock<MockDemuxer> demuxer_; 133 NiceMock<MockDemuxer> demuxer_;
132 StrictMock<MockPipeline> pipeline_; 134 StrictMock<MockPipeline> pipeline_;
133 PipelineController pipeline_controller_; 135 PipelineController pipeline_controller_;
134 136
135 bool was_seeked_ = false; 137 bool was_seeked_ = false;
136 bool last_seeked_time_updated_ = false; 138 bool last_seeked_time_updated_ = false;
137 bool was_suspended_ = false; 139 bool was_suspended_ = false;
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
314 // Request a seek to the same time again. 316 // Request a seek to the same time again.
315 pipeline_controller_.Seek(seek_time, true); 317 pipeline_controller_.Seek(seek_time, true);
316 message_loop_.RunUntilIdle(); 318 message_loop_.RunUntilIdle();
317 319
318 // Expect the second seek to trigger when the first seek completes. 320 // Expect the second seek to trigger when the first seek completes.
319 EXPECT_CALL(pipeline_, Seek(seek_time, _)); 321 EXPECT_CALL(pipeline_, Seek(seek_time, _));
320 Complete(seek_cb_1); 322 Complete(seek_cb_1);
321 } 323 }
322 324
323 } // namespace media 325 } // namespace media
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698