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

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

Issue 18123002: Migrate webkit/renderer/media/ to content/renderer/media/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "content/renderer/media/webaudiosourceprovider_impl.h"
5 #include "media/audio/audio_parameters.h" 6 #include "media/audio/audio_parameters.h"
6 #include "media/base/fake_audio_render_callback.h" 7 #include "media/base/fake_audio_render_callback.h"
7 #include "media/base/mock_audio_renderer_sink.h" 8 #include "media/base/mock_audio_renderer_sink.h"
8 #include "testing/gmock/include/gmock/gmock.h" 9 #include "testing/gmock/include/gmock/gmock.h"
9 #include "testing/gtest/include/gtest/gtest.h" 10 #include "testing/gtest/include/gtest/gtest.h"
10 #include "third_party/WebKit/public/web/WebAudioSourceProviderClient.h" 11 #include "third_party/WebKit/public/web/WebAudioSourceProviderClient.h"
11 #include "webkit/renderer/media/webaudiosourceprovider_impl.h"
12 12
13 namespace webkit_media { 13 namespace content {
14 14
15 namespace { 15 namespace {
16 const float kTestVolume = 0.25; 16 const float kTestVolume = 0.25;
17 } // namespace 17 } // namespace
18 18
19 class WebAudioSourceProviderImplTest 19 class WebAudioSourceProviderImplTest
20 : public testing::Test, 20 : public testing::Test,
21 public WebKit::WebAudioSourceProviderClient { 21 public WebKit::WebAudioSourceProviderClient {
22 public: 22 public:
23 WebAudioSourceProviderImplTest() 23 WebAudioSourceProviderImplTest()
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 wasp_impl_->provideInput(audio_data, params_.frames_per_buffer()); 211 wasp_impl_->provideInput(audio_data, params_.frames_per_buffer());
212 ASSERT_FALSE(CompareBusses(bus1.get(), bus2.get())); 212 ASSERT_FALSE(CompareBusses(bus1.get(), bus2.get()));
213 213
214 // Stop() should return silence. 214 // Stop() should return silence.
215 wasp_impl_->Stop(); 215 wasp_impl_->Stop();
216 bus1->channel(0)[0] = 1; 216 bus1->channel(0)[0] = 1;
217 wasp_impl_->provideInput(audio_data, params_.frames_per_buffer()); 217 wasp_impl_->provideInput(audio_data, params_.frames_per_buffer());
218 ASSERT_TRUE(CompareBusses(bus1.get(), bus2.get())); 218 ASSERT_TRUE(CompareBusses(bus1.get(), bus2.get()));
219 } 219 }
220 220
221 } // namespace webkit_media 221 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698