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

Side by Side Diff: media/audio/audio_output_proxy_unittest.cc

Issue 10830268: Allow audio system to handle synchronized low-latency audio I/O (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 3 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <string> 5 #include <string>
6 6
7 #include "base/message_loop.h" 7 #include "base/message_loop.h"
8 #include "base/message_loop_proxy.h" 8 #include "base/message_loop_proxy.h"
9 #include "base/threading/platform_thread.h" 9 #include "base/threading/platform_thread.h"
10 #include "media/audio/audio_output_dispatcher_impl.h" 10 #include "media/audio/audio_output_dispatcher_impl.h"
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 MOCK_METHOD0(GetMessageLoop, scoped_refptr<base::MessageLoopProxy>()); 75 MOCK_METHOD0(GetMessageLoop, scoped_refptr<base::MessageLoopProxy>());
76 MOCK_METHOD1(GetAudioInputDeviceNames, void( 76 MOCK_METHOD1(GetAudioInputDeviceNames, void(
77 media::AudioDeviceNames* device_name)); 77 media::AudioDeviceNames* device_name));
78 MOCK_METHOD0(IsRecordingInProcess, bool()); 78 MOCK_METHOD0(IsRecordingInProcess, bool());
79 }; 79 };
80 80
81 class MockAudioSourceCallback : public AudioOutputStream::AudioSourceCallback { 81 class MockAudioSourceCallback : public AudioOutputStream::AudioSourceCallback {
82 public: 82 public:
83 MOCK_METHOD2(OnMoreData, int(AudioBus* audio_bus, 83 MOCK_METHOD2(OnMoreData, int(AudioBus* audio_bus,
84 AudioBuffersState buffers_state)); 84 AudioBuffersState buffers_state));
85 MOCK_METHOD3(OnMoreIOData, int(AudioBus* source,
86 AudioBus* dest,
87 AudioBuffersState buffers_state));
85 MOCK_METHOD2(OnError, void(AudioOutputStream* stream, int code)); 88 MOCK_METHOD2(OnError, void(AudioOutputStream* stream, int code));
86 }; 89 };
87 90
88 } // namespace 91 } // namespace
89 92
90 namespace media { 93 namespace media {
91 94
92 class AudioOutputProxyTest : public testing::Test { 95 class AudioOutputProxyTest : public testing::Test {
93 protected: 96 protected:
94 virtual void SetUp() { 97 virtual void SetUp() {
(...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after
674 proxy2->Close(); 677 proxy2->Close();
675 WaitForCloseTimer(kTestCloseDelayMs); 678 WaitForCloseTimer(kTestCloseDelayMs);
676 } 679 }
677 #endif 680 #endif
678 681
679 TEST_F(AudioOutputProxyTest, StartFailed_Resampler) { 682 TEST_F(AudioOutputProxyTest, StartFailed_Resampler) {
680 StartFailed(resampler_); 683 StartFailed(resampler_);
681 } 684 }
682 685
683 } // namespace media 686 } // namespace media
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698