| OLD | NEW |
| 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 "content/browser/renderer_host/media/audio_output_delegate_impl.h" | 5 #include "content/browser/renderer_host/media/audio_output_delegate_impl.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 void OnSetCapturingLinkSecured(int render_process_id, | 69 void OnSetCapturingLinkSecured(int render_process_id, |
| 70 int render_frame_id, | 70 int render_frame_id, |
| 71 int page_request_id, | 71 int page_request_id, |
| 72 MediaStreamType stream_type, | 72 MediaStreamType stream_type, |
| 73 bool is_secure) override {} | 73 bool is_secure) override {} |
| 74 | 74 |
| 75 MOCK_METHOD2(OnCreatingAudioStream, | 75 MOCK_METHOD2(OnCreatingAudioStream, |
| 76 void(int render_process_id, int render_frame_id)); | 76 void(int render_process_id, int render_frame_id)); |
| 77 }; | 77 }; |
| 78 | 78 |
| 79 class MockEventHandler : public AudioOutputDelegate::EventHandler { | 79 class MockEventHandler : public media::AudioOutputDelegate::EventHandler { |
| 80 public: | 80 public: |
| 81 MOCK_METHOD3(OnStreamCreated, | 81 MOCK_METHOD3(OnStreamCreated, |
| 82 void(int stream_id, | 82 void(int stream_id, |
| 83 base::SharedMemory* shared_memory, | 83 base::SharedMemory* shared_memory, |
| 84 base::CancelableSyncSocket* socket)); | 84 base::CancelableSyncSocket* socket)); |
| 85 MOCK_METHOD1(OnStreamError, void(int stream_id)); | 85 MOCK_METHOD1(OnStreamError, void(int stream_id)); |
| 86 }; | 86 }; |
| 87 | 87 |
| 88 class DummyAudioOutputStream : public media::AudioOutputStream { | 88 class DummyAudioOutputStream : public media::AudioOutputStream { |
| 89 public: | 89 public: |
| (...skipping 480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 570 TEST_F(AudioOutputDelegateTest, ErrorAndDestroy) { | 570 TEST_F(AudioOutputDelegateTest, ErrorAndDestroy) { |
| 571 base::RunLoop l; | 571 base::RunLoop l; |
| 572 BrowserThread::PostTask( | 572 BrowserThread::PostTask( |
| 573 BrowserThread::IO, FROM_HERE, | 573 BrowserThread::IO, FROM_HERE, |
| 574 base::Bind(&AudioOutputDelegateTest::PlayAndDestroyTest, | 574 base::Bind(&AudioOutputDelegateTest::PlayAndDestroyTest, |
| 575 base::Unretained(this), l.QuitClosure())); | 575 base::Unretained(this), l.QuitClosure())); |
| 576 l.Run(); | 576 l.Run(); |
| 577 } | 577 } |
| 578 | 578 |
| 579 } // namespace content | 579 } // namespace content |
| OLD | NEW |