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

Side by Side Diff: content/test/mock_audio_stream_registry.cc

Issue 2578983003: Add AudioStreamRegistry. Move stream counting logic (Closed)
Patch Set: Add missing EXPECT_TRUE. Created 3 years, 12 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_BROWSER_RENDERER_HOST_MEDIA_MOCK_AUDIO_STREAM_REGISTRY_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_MEDIA_MOCK_AUDIO_STREAM_REGISTRY_H_
7
8 #include "content/test/mock_audio_stream_registry.h"
9
10 #include "testing/gmock/include/gmock/gmock.h"
11
12 namespace content {
13
14 MockAudioStreamRegistry::MockAudioStreamRegistry(int render_process_id)
15 : impl_(render_process_id) {
16 // AudioStreamRegistryImpl has many DCHECKs. We reuse them here by
17 // forwarding all calls.
18 ON_CALL(*this, RegisterOutputStream(testing::_))
19 .WillByDefault(
20 testing::Invoke(&impl_, &AudioStreamRegistry::RegisterOutputStream));
21 ON_CALL(*this, DeregisterOutputStream(testing::_))
22 .WillByDefault(testing::Invoke(
23 &impl_, &AudioStreamRegistry::DeregisterOutputStream));
24 ON_CALL(*this, OutputStreamStateChanged(testing::_, testing::_))
25 .WillByDefault(testing::Invoke(
26 &impl_, &AudioStreamRegistry::OutputStreamStateChanged));
27 }
28
29 MockAudioStreamRegistry::~MockAudioStreamRegistry() {}
30
31 } // namespace content
32
33 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_MOCK_AUDIO_STREAM_REGISTRY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698