| Index: media/base/mock_filters.h
|
| diff --git a/media/base/mock_filters.h b/media/base/mock_filters.h
|
| index 6068a7f988d9c01f79f5aa3cc3c6cdfd738d37e9..b1d838f53d36906681218963d239ae983bc66925 100644
|
| --- a/media/base/mock_filters.h
|
| +++ b/media/base/mock_filters.h
|
| @@ -199,23 +199,22 @@ class MockAudioRenderer : public AudioRenderer {
|
| public:
|
| MockAudioRenderer();
|
|
|
| - // Filter implementation.
|
| - MOCK_METHOD1(SetHost, void(FilterHost* host));
|
| + // AudioRenderer implementation.
|
| + MOCK_METHOD7(Initialize, void(const scoped_refptr<AudioDecoder>& decoder,
|
| + const PipelineStatusCB& init_cb,
|
| + const base::Closure& underflow_cb,
|
| + const TimeCB& time_cb,
|
| + const base::Closure& ended_cb,
|
| + const base::Closure& disabled_cb,
|
| + const PipelineStatusCB& error_cb));
|
| MOCK_METHOD1(Play, void(const base::Closure& callback));
|
| MOCK_METHOD1(Pause, void(const base::Closure& callback));
|
| MOCK_METHOD1(Flush, void(const base::Closure& callback));
|
| MOCK_METHOD1(Stop, void(const base::Closure& callback));
|
| MOCK_METHOD1(SetPlaybackRate, void(float playback_rate));
|
| MOCK_METHOD2(Seek, void(base::TimeDelta time, const PipelineStatusCB& cb));
|
| -
|
| - // AudioRenderer implementation.
|
| - MOCK_METHOD4(Initialize, void(const scoped_refptr<AudioDecoder>& decoder,
|
| - const PipelineStatusCB& init_cb,
|
| - const base::Closure& underflow_cb,
|
| - const TimeCB& time_cb));
|
| MOCK_METHOD0(HasEnded, bool());
|
| MOCK_METHOD1(SetVolume, void(float volume));
|
| -
|
| MOCK_METHOD1(ResumeAfterUnderflow, void(bool buffer_more_audio));
|
|
|
| protected:
|
| @@ -310,19 +309,6 @@ class MockFilterCollection {
|
| DISALLOW_COPY_AND_ASSIGN(MockFilterCollection);
|
| };
|
|
|
| -// Helper gmock functions that immediately executes and destroys the
|
| -// Closure on behalf of the provided filter. Can be used when mocking
|
| -// the Initialize() and Seek() methods.
|
| -void RunPipelineStatusCB(const PipelineStatusCB& status_cb);
|
| -void RunPipelineStatusCB2(::testing::Unused, const PipelineStatusCB& status_cb);
|
| -void RunPipelineStatusCB3(::testing::Unused, const PipelineStatusCB& status_cb,
|
| - ::testing::Unused);
|
| -void RunPipelineStatusCB4(::testing::Unused, const PipelineStatusCB& status_cb,
|
| - ::testing::Unused, ::testing::Unused);
|
| -// Helper gmock function that immediately executes the Closure on behalf of the
|
| -// provided filter. Can be used when mocking the Stop() method.
|
| -void RunClosure(const base::Closure& closure);
|
| -
|
| // Helper gmock action that calls SetError() on behalf of the provided filter.
|
| ACTION_P2(SetError, filter, error) {
|
| filter->host()->SetError(error);
|
| @@ -334,6 +320,10 @@ ACTION_P2(SetDuration, filter, duration) {
|
| filter->host()->SetDuration(duration);
|
| }
|
|
|
| +ACTION(RunClosure) {
|
| + arg0.Run();
|
| +}
|
| +
|
| // Helper mock statistics callback.
|
| class MockStatisticsCB {
|
| public:
|
|
|