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

Side by Side Diff: media/audio/win/audio_device_listener_win_unittest.cc

Issue 1250933002: clang/win: Fix build after https://codereview.chromium.org/1248543002/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <string> 5 #include <string>
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
11 #include "base/test/simple_test_tick_clock.h" 11 #include "base/test/simple_test_tick_clock.h"
12 #include "base/win/scoped_com_initializer.h" 12 #include "base/win/scoped_com_initializer.h"
13 #include "media/audio/audio_manager.h" 13 #include "media/audio/audio_manager.h"
14 #include "media/audio/audio_unittest_util.h" 14 #include "media/audio/audio_unittest_util.h"
15 #include "media/audio/win/audio_device_listener_win.h" 15 #include "media/audio/win/audio_device_listener_win.h"
16 #include "media/audio/win/core_audio_util_win.h" 16 #include "media/audio/win/core_audio_util_win.h"
17 #include "testing/gmock/include/gmock/gmock.h" 17 #include "testing/gmock/include/gmock/gmock.h"
18 #include "testing/gtest/include/gtest/gtest.h" 18 #include "testing/gtest/include/gtest/gtest.h"
19 19
20 using base::win::ScopedCOMInitializer; 20 using base::win::ScopedCOMInitializer;
21 21
22 namespace media { 22 namespace media {
23 23
24 static const char kNoDevice[] = "";
25 static const char kFirstTestDevice[] = "test_device_0"; 24 static const char kFirstTestDevice[] = "test_device_0";
26 static const char kSecondTestDevice[] = "test_device_1"; 25 static const char kSecondTestDevice[] = "test_device_1";
27 26
28 class AudioDeviceListenerWinTest : public testing::Test { 27 class AudioDeviceListenerWinTest : public testing::Test {
29 public: 28 public:
30 AudioDeviceListenerWinTest() { 29 AudioDeviceListenerWinTest() {
31 DCHECK(com_init_.succeeded()); 30 DCHECK(com_init_.succeeded());
32 } 31 }
33 32
34 virtual void SetUp() { 33 virtual void SetUp() {
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 EXPECT_CALL(*this, OnDeviceChange()).Times(1); 100 EXPECT_CALL(*this, OnDeviceChange()).Times(1);
102 ASSERT_TRUE(SimulateDefaultOutputDeviceChange(kFirstTestDevice)); 101 ASSERT_TRUE(SimulateDefaultOutputDeviceChange(kFirstTestDevice));
103 102
104 testing::Mock::VerifyAndClear(this); 103 testing::Mock::VerifyAndClear(this);
105 AdvanceLastDeviceChangeTime(); 104 AdvanceLastDeviceChangeTime();
106 EXPECT_CALL(*this, OnDeviceChange()).Times(1); 105 EXPECT_CALL(*this, OnDeviceChange()).Times(1);
107 ASSERT_TRUE(SimulateNullDefaultOutputDeviceChange()); 106 ASSERT_TRUE(SimulateNullDefaultOutputDeviceChange());
108 } 107 }
109 108
110 } // namespace media 109 } // namespace media
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698