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

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

Issue 1031943004: Disable TestWithKeyboardMicChannel for android clang builds (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
« 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 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 "base/files/file_path.h" 5 #include "base/files/file_path.h"
6 #include "base/files/file_util.h" 6 #include "base/files/file_util.h"
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/memory/aligned_memory.h" 8 #include "base/memory/aligned_memory.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/time/time.h" 10 #include "base/time/time.h"
(...skipping 474 matching lines...) Expand 10 before | Expand all | Expand 10 after
485 EXPECT_EQ(processed_data->channel(0)[0], 0); 485 EXPECT_EQ(processed_data->channel(0)[0], 0);
486 EXPECT_NE(processed_data->channel(1)[0], 0); 486 EXPECT_NE(processed_data->channel(1)[0], 0);
487 EXPECT_EQ(pushed_capture_delay, capture_delay); 487 EXPECT_EQ(pushed_capture_delay, capture_delay);
488 } 488 }
489 489
490 // Set |audio_processor| to NULL to make sure |webrtc_audio_device| outlives 490 // Set |audio_processor| to NULL to make sure |webrtc_audio_device| outlives
491 // |audio_processor|. 491 // |audio_processor|.
492 audio_processor = NULL; 492 audio_processor = NULL;
493 } 493 }
494 494
495 TEST_F(MediaStreamAudioProcessorTest, TestWithKeyboardMicChannel) { 495 // Disabled on android clang builds due to crbug.com/470499
496 #if defined(__clang__) && defined(OS_ANDROID)
497 #define MAYBE_TestWithKeyboardMicChannel DISABLED_TestWithKeyboardMicChannel
498 #else
499 #define MAYBE_TestWithKeyboardMicChannel TestWithKeyboardMicChannel
500 #endif
501
502 TEST_F(MediaStreamAudioProcessorTest, MAYBE_TestWithKeyboardMicChannel) {
496 MockMediaConstraintFactory constraint_factory; 503 MockMediaConstraintFactory constraint_factory;
497 constraint_factory.AddMandatory( 504 constraint_factory.AddMandatory(
498 MediaAudioConstraints::kGoogExperimentalNoiseSuppression, true); 505 MediaAudioConstraints::kGoogExperimentalNoiseSuppression, true);
499 scoped_refptr<WebRtcAudioDeviceImpl> webrtc_audio_device( 506 scoped_refptr<WebRtcAudioDeviceImpl> webrtc_audio_device(
500 new WebRtcAudioDeviceImpl()); 507 new WebRtcAudioDeviceImpl());
501 scoped_refptr<MediaStreamAudioProcessor> audio_processor( 508 scoped_refptr<MediaStreamAudioProcessor> audio_processor(
502 new rtc::RefCountedObject<MediaStreamAudioProcessor>( 509 new rtc::RefCountedObject<MediaStreamAudioProcessor>(
503 constraint_factory.CreateWebMediaConstraints(), 0, 510 constraint_factory.CreateWebMediaConstraints(), 0,
504 webrtc_audio_device.get())); 511 webrtc_audio_device.get()));
505 EXPECT_TRUE(audio_processor->has_audio_processing()); 512 EXPECT_TRUE(audio_processor->has_audio_processing());
506 513
507 media::AudioParameters params(media::AudioParameters::AUDIO_PCM_LOW_LATENCY, 514 media::AudioParameters params(media::AudioParameters::AUDIO_PCM_LOW_LATENCY,
508 media::CHANNEL_LAYOUT_STEREO_AND_KEYBOARD_MIC, 515 media::CHANNEL_LAYOUT_STEREO_AND_KEYBOARD_MIC,
509 48000, 16, 512); 516 48000, 16, 512);
510 audio_processor->OnCaptureFormatChanged(params); 517 audio_processor->OnCaptureFormatChanged(params);
511 518
512 ProcessDataAndVerifyFormat(audio_processor.get(), 519 ProcessDataAndVerifyFormat(audio_processor.get(),
513 kAudioProcessingSampleRate, 520 kAudioProcessingSampleRate,
514 kAudioProcessingNumberOfChannel, 521 kAudioProcessingNumberOfChannel,
515 kAudioProcessingSampleRate / 100); 522 kAudioProcessingSampleRate / 100);
516 // Set |audio_processor| to NULL to make sure |webrtc_audio_device| outlives 523 // Set |audio_processor| to NULL to make sure |webrtc_audio_device| outlives
517 // |audio_processor|. 524 // |audio_processor|.
518 audio_processor = NULL; 525 audio_processor = NULL;
519 } 526 }
520 527
521 } // namespace content 528 } // namespace content
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