| OLD | NEW |
| 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 "base/basictypes.h" | 5 #include "base/basictypes.h" |
| 6 #include "base/bind.h" | 6 #include "base/bind.h" |
| 7 #include "base/environment.h" | 7 #include "base/environment.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 class MockAudioOutputControllerEventHandler | 36 class MockAudioOutputControllerEventHandler |
| 37 : public AudioOutputController::EventHandler { | 37 : public AudioOutputController::EventHandler { |
| 38 public: | 38 public: |
| 39 MockAudioOutputControllerEventHandler() {} | 39 MockAudioOutputControllerEventHandler() {} |
| 40 | 40 |
| 41 MOCK_METHOD1(OnCreated, void(AudioOutputController* controller)); | 41 MOCK_METHOD1(OnCreated, void(AudioOutputController* controller)); |
| 42 MOCK_METHOD1(OnPlaying, void(AudioOutputController* controller)); | 42 MOCK_METHOD1(OnPlaying, void(AudioOutputController* controller)); |
| 43 MOCK_METHOD1(OnPaused, void(AudioOutputController* controller)); | 43 MOCK_METHOD1(OnPaused, void(AudioOutputController* controller)); |
| 44 MOCK_METHOD2(OnError, void(AudioOutputController* controller, | 44 MOCK_METHOD2(OnError, void(AudioOutputController* controller, |
| 45 int error_code)); | 45 int error_code)); |
| 46 | 46 MOCK_METHOD3(OnDeviceChange, void(AudioOutputController* controller, |
| 47 int new_buffer_size, int new_sample_rate)); |
| 47 private: | 48 private: |
| 48 DISALLOW_COPY_AND_ASSIGN(MockAudioOutputControllerEventHandler); | 49 DISALLOW_COPY_AND_ASSIGN(MockAudioOutputControllerEventHandler); |
| 49 }; | 50 }; |
| 50 | 51 |
| 51 class MockAudioOutputControllerSyncReader | 52 class MockAudioOutputControllerSyncReader |
| 52 : public AudioOutputController::SyncReader { | 53 : public AudioOutputController::SyncReader { |
| 53 public: | 54 public: |
| 54 MockAudioOutputControllerSyncReader() {} | 55 MockAudioOutputControllerSyncReader() {} |
| 55 | 56 |
| 56 MOCK_METHOD1(UpdatePendingBytes, void(uint32 bytes)); | 57 MOCK_METHOD1(UpdatePendingBytes, void(uint32 bytes)); |
| (...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 370 | 371 |
| 371 TEST_F(AudioOutputControllerTest, DivertRevertClose) { | 372 TEST_F(AudioOutputControllerTest, DivertRevertClose) { |
| 372 Create(kSamplesPerPacket); | 373 Create(kSamplesPerPacket); |
| 373 WaitForCreate(); | 374 WaitForCreate(); |
| 374 DivertNeverPlaying(); | 375 DivertNeverPlaying(); |
| 375 RevertWasNotPlaying(); | 376 RevertWasNotPlaying(); |
| 376 Close(); | 377 Close(); |
| 377 } | 378 } |
| 378 | 379 |
| 379 } // namespace media | 380 } // namespace media |
| OLD | NEW |