Index: content/renderer/media/webrtc/webrtc_media_stream_adapter_unittest.cc |
diff --git a/content/renderer/media/webrtc/webrtc_media_stream_adapter_unittest.cc b/content/renderer/media/webrtc/webrtc_media_stream_adapter_unittest.cc |
index 26546f4fda07e93a8c25dffd90e754de9d05c54a..d23cfa9bfa2e40c931c3730e827f26740a06455e 100644 |
--- a/content/renderer/media/webrtc/webrtc_media_stream_adapter_unittest.cc |
+++ b/content/renderer/media/webrtc/webrtc_media_stream_adapter_unittest.cc |
@@ -11,6 +11,7 @@ |
#include "content/renderer/media/media_stream_audio_source.h" |
#include "content/renderer/media/media_stream_video_source.h" |
#include "content/renderer/media/media_stream_video_track.h" |
+#include "content/renderer/media/mock_media_constraint_factory.h" |
#include "content/renderer/media/mock_media_stream_video_source.h" |
#include "content/renderer/media/webrtc/mock_peer_connection_dependency_factory.h" |
#include "content/renderer/media/webrtc/webrtc_local_audio_track_adapter.h" |
@@ -49,11 +50,19 @@ |
audio_source.setExtraData(new MediaStreamAudioSource()); |
audio_track_vector[0].initialize(audio_source); |
+ StreamDeviceInfo device_info(MEDIA_DEVICE_AUDIO_CAPTURE, "Mock device", |
+ "mock_device_id"); |
+ MockMediaConstraintFactory constraint_factory; |
+ const blink::WebMediaConstraints constraints = |
+ constraint_factory.CreateWebMediaConstraints(); |
+ scoped_refptr<WebRtcAudioCapturer> capturer( |
+ WebRtcAudioCapturer::CreateCapturer(-1, device_info, constraints, |
+ nullptr, nullptr)); |
scoped_refptr<WebRtcLocalAudioTrackAdapter> adapter( |
WebRtcLocalAudioTrackAdapter::Create( |
audio_track_vector[0].id().utf8(), nullptr)); |
scoped_ptr<WebRtcLocalAudioTrack> native_track( |
- new WebRtcLocalAudioTrack(adapter.get())); |
+ new WebRtcLocalAudioTrack(adapter.get(), capturer, nullptr)); |
audio_track_vector[0].setExtraData(native_track.release()); |
} |