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

Unified Diff: content/renderer/media/webrtc_local_audio_source_provider_unittest.cc

Issue 1721273002: MediaStream audio object graph untangling and clean-ups. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix unit tests broken by recent MSAudioTrack::Stop() reworking. Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: content/renderer/media/webrtc_local_audio_source_provider_unittest.cc
diff --git a/content/renderer/media/webrtc_local_audio_source_provider_unittest.cc b/content/renderer/media/webrtc_local_audio_source_provider_unittest.cc
index 28acddd2d4fe3fc60b928df5aff93926c60e4a32..df0c6e8a9d9150380a30a362d1d5f67f028da6ae 100644
--- a/content/renderer/media/webrtc_local_audio_source_provider_unittest.cc
+++ b/content/renderer/media/webrtc_local_audio_source_provider_unittest.cc
@@ -5,16 +5,14 @@
#include <stddef.h>
#include "base/logging.h"
-#include "base/strings/utf_string_conversions.h"
-#include "content/renderer/media/mock_media_constraint_factory.h"
#include "content/renderer/media/webrtc/webrtc_local_audio_track_adapter.h"
-#include "content/renderer/media/webrtc_audio_capturer.h"
#include "content/renderer/media/webrtc_local_audio_source_provider.h"
#include "content/renderer/media/webrtc_local_audio_track.h"
#include "media/audio/audio_parameters.h"
#include "media/base/audio_bus.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/WebKit/public/platform/WebMediaStreamTrack.h"
+#include "third_party/WebKit/public/platform/WebString.h"
#include "third_party/WebKit/public/web/WebHeap.h"
namespace content {
@@ -29,19 +27,14 @@ class WebRtcLocalAudioSourceProviderTest : public testing::Test {
media::CHANNEL_LAYOUT_STEREO, 44100, 16,
WebRtcLocalAudioSourceProvider::kWebAudioRenderBufferSize);
sink_bus_ = media::AudioBus::Create(sink_params_);
- MockMediaConstraintFactory constraint_factory;
- scoped_refptr<WebRtcAudioCapturer> capturer(
- WebRtcAudioCapturer::CreateCapturer(
- -1, StreamDeviceInfo(),
- constraint_factory.CreateWebMediaConstraints(), NULL, NULL));
scoped_refptr<WebRtcLocalAudioTrackAdapter> adapter(
WebRtcLocalAudioTrackAdapter::Create(std::string(), NULL));
scoped_ptr<WebRtcLocalAudioTrack> native_track(
- new WebRtcLocalAudioTrack(adapter.get(), capturer, NULL));
+ new WebRtcLocalAudioTrack(adapter.get()));
blink::WebMediaStreamSource audio_source;
- audio_source.initialize(base::UTF8ToUTF16("dummy_source_id"),
+ audio_source.initialize(blink::WebString::fromUTF8("dummy_source_id"),
blink::WebMediaStreamSource::TypeAudio,
- base::UTF8ToUTF16("dummy_source_name"),
+ blink::WebString::fromUTF8("dummy_source_name"),
false /* remote */, true /* readonly */);
blink_track_.initialize(blink::WebString::fromUTF8("audio_track"),
audio_source);

Powered by Google App Engine
This is Rietveld 408576698