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

Side by Side Diff: media/audio/android/audio_android_unittest.cc

Issue 613153003: Reenable AudioAndroidOutputTest.StartOutputStreamCallbacks on Arm64. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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/android/build_info.h" 5 #include "base/android/build_info.h"
6 #include "base/basictypes.h" 6 #include "base/basictypes.h"
7 #include "base/files/file_util.h" 7 #include "base/files/file_util.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 793 matching lines...) Expand 10 before | Expand all | Expand 10 after
804 AudioParameters native_params = GetInputStreamParameters(); 804 AudioParameters native_params = GetInputStreamParameters();
805 AudioParameters params(native_params.format(), 805 AudioParameters params(native_params.format(),
806 native_params.channel_layout(), 806 native_params.channel_layout(),
807 native_params.sample_rate(), 807 native_params.sample_rate(),
808 native_params.bits_per_sample(), 808 native_params.bits_per_sample(),
809 native_params.sample_rate() / 100, 809 native_params.sample_rate() / 100,
810 native_params.effects()); 810 native_params.effects());
811 StartInputStreamCallbacks(params); 811 StartInputStreamCallbacks(params);
812 } 812 }
813 813
814
815 #if defined(__aarch64__)
816 // Disable StartOutputStreamCallbacks and
817 // StartOutputStreamCallbacksNonDefaultParameters on Arm64: crbug.com/418029
818 #define MAYBE_StartOutputStreamCallbacks DISABLED_StartOutputStreamCallbacks
819 #define MAYBE_StartOutputStreamCallbacksNonDefaultParameters \
820 DISABLED_StartOutputStreamCallbacksNonDefaultParameters
821 #else
822 #define MAYBE_StartOutputStreamCallbacks StartOutputStreamCallbacks
823 #define MAYBE_StartOutputStreamCallbacksNonDefaultParameters \
824 StartOutputStreamCallbacksNonDefaultParameters
825 #endif
826
827
828 // Start output streaming using default output parameters and ensure that the 814 // Start output streaming using default output parameters and ensure that the
829 // callback sequence is sane. 815 // callback sequence is sane.
830 TEST_F(AudioAndroidOutputTest, MAYBE_StartOutputStreamCallbacks) { 816 TEST_F(AudioAndroidOutputTest, StartOutputStreamCallbacks) {
831 GetDefaultOutputStreamParametersOnAudioThread(); 817 GetDefaultOutputStreamParametersOnAudioThread();
832 StartOutputStreamCallbacks(audio_output_parameters()); 818 StartOutputStreamCallbacks(audio_output_parameters());
833 } 819 }
834 820
835 // Start output streaming using non default output parameters and ensure that 821 // Start output streaming using non default output parameters and ensure that
836 // the callback sequence is sane. The only change we make in this test is to 822 // the callback sequence is sane. The only change we make in this test is to
837 // select a 10ms buffer size instead of the default size and to open up the 823 // select a 10ms buffer size instead of the default size and to open up the
838 // device in mono. 824 // device in mono.
839 // TODO(henrika): possibly add support for more variations. 825 // TODO(henrika): possibly add support for more variations.
840 TEST_F(AudioAndroidOutputTest, 826 TEST_F(AudioAndroidOutputTest, StartOutputStreamCallbacksNonDefaultParameters) {
841 MAYBE_StartOutputStreamCallbacksNonDefaultParameters) {
842 GetDefaultOutputStreamParametersOnAudioThread(); 827 GetDefaultOutputStreamParametersOnAudioThread();
843 AudioParameters params(audio_output_parameters().format(), 828 AudioParameters params(audio_output_parameters().format(),
844 CHANNEL_LAYOUT_MONO, 829 CHANNEL_LAYOUT_MONO,
845 audio_output_parameters().sample_rate(), 830 audio_output_parameters().sample_rate(),
846 audio_output_parameters().bits_per_sample(), 831 audio_output_parameters().bits_per_sample(),
847 audio_output_parameters().sample_rate() / 100); 832 audio_output_parameters().sample_rate() / 100);
848 StartOutputStreamCallbacks(params); 833 StartOutputStreamCallbacks(params);
849 } 834 }
850 835
851 // Play out a PCM file segment in real time and allow the user to verify that 836 // Play out a PCM file segment in real time and allow the user to verify that
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
982 base::PlatformThread::Sleep(base::TimeDelta::FromSeconds(20)); 967 base::PlatformThread::Sleep(base::TimeDelta::FromSeconds(20));
983 printf("\n"); 968 printf("\n");
984 StopAndCloseAudioOutputStreamOnAudioThread(); 969 StopAndCloseAudioOutputStreamOnAudioThread();
985 StopAndCloseAudioInputStreamOnAudioThread(); 970 StopAndCloseAudioInputStreamOnAudioThread();
986 } 971 }
987 972
988 INSTANTIATE_TEST_CASE_P(AudioAndroidInputTest, AudioAndroidInputTest, 973 INSTANTIATE_TEST_CASE_P(AudioAndroidInputTest, AudioAndroidInputTest,
989 testing::ValuesIn(RunAudioRecordInputPathTests())); 974 testing::ValuesIn(RunAudioRecordInputPathTests()));
990 975
991 } // namespace media 976 } // 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