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

Side by Side Diff: content/renderer/media/media_stream_audio_unittest.cc

Issue 2425703002: Remove |remote| and |readonly| members of MediaStreamTrack (Closed)
Patch Set: Fixed webkit_tests Created 3 years, 9 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
OLDNEW
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 <stdint.h> 5 #include <stdint.h>
6 6
7 #include "base/atomicops.h" 7 #include "base/atomicops.h"
8 #include "base/message_loop/message_loop.h" 8 #include "base/message_loop/message_loop.h"
9 #include "base/synchronization/lock.h" 9 #include "base/synchronization/lock.h"
10 #include "base/synchronization/waitable_event.h" 10 #include "base/synchronization/waitable_event.h"
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
236 DISALLOW_COPY_AND_ASSIGN(FakeMediaStreamAudioSink); 236 DISALLOW_COPY_AND_ASSIGN(FakeMediaStreamAudioSink);
237 }; 237 };
238 238
239 } // namespace 239 } // namespace
240 240
241 class MediaStreamAudioTest : public ::testing::Test { 241 class MediaStreamAudioTest : public ::testing::Test {
242 protected: 242 protected:
243 void SetUp() override { 243 void SetUp() override {
244 blink_audio_source_.initialize(blink::WebString::fromUTF8("audio_id"), 244 blink_audio_source_.initialize(blink::WebString::fromUTF8("audio_id"),
245 blink::WebMediaStreamSource::TypeAudio, 245 blink::WebMediaStreamSource::TypeAudio,
246 blink::WebString::fromUTF8("audio_track"), 246 blink::WebString::fromUTF8("audio_track"));
247 false /* remote */);
248 blink_audio_track_.initialize(blink_audio_source_.id(), 247 blink_audio_track_.initialize(blink_audio_source_.id(),
249 blink_audio_source_); 248 blink_audio_source_);
250 } 249 }
251 250
252 void TearDown() override { 251 void TearDown() override {
253 blink_audio_track_.reset(); 252 blink_audio_track_.reset();
254 blink_audio_source_.reset(); 253 blink_audio_source_.reset();
255 blink::WebHeap::collectAllGarbageForTesting(); 254 blink::WebHeap::collectAllGarbageForTesting();
256 } 255 }
257 256
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after
447 // enabled state of the second track and sink. They should still be disabled, 446 // enabled state of the second track and sink. They should still be disabled,
448 // with silent audio being consumed at the sink. 447 // with silent audio being consumed at the sink.
449 EXPECT_EQ(FakeMediaStreamAudioSink::WAS_DISABLED, sink.enable_state()); 448 EXPECT_EQ(FakeMediaStreamAudioSink::WAS_DISABLED, sink.enable_state());
450 EXPECT_TRUE(sink.is_audio_silent()); 449 EXPECT_TRUE(sink.is_audio_silent());
451 450
452 MediaStreamAudioTrack::From(another_blink_track)->RemoveSink(&another_sink); 451 MediaStreamAudioTrack::From(another_blink_track)->RemoveSink(&another_sink);
453 track()->RemoveSink(&sink); 452 track()->RemoveSink(&sink);
454 } 453 }
455 454
456 } // namespace content 455 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698