summaryrefslogtreecommitdiffstats
path: root/audio
diff options
context:
space:
mode:
authorMikhail Naganov <mnaganov@google.com>2020-03-19 00:36:49 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-03-19 00:36:49 +0000
commit6c3c46c2c5a5283a1c034e87eeb2dd304567ff37 (patch)
treef0fc78f6adfb57cf7fd435e0549cbe5e227015f8 /audio
parent211533c5568b3fb15f0a809be2a6ecc5d625fffa (diff)
parent8c32e628bed98d2bd4f0f97baf35a354567bd12c (diff)
downloadplatform_hardware_interfaces-6c3c46c2c5a5283a1c034e87eeb2dd304567ff37.tar.gz
platform_hardware_interfaces-6c3c46c2c5a5283a1c034e87eeb2dd304567ff37.tar.bz2
platform_hardware_interfaces-6c3c46c2c5a5283a1c034e87eeb2dd304567ff37.zip
Audio Effects: Skip CheckConfig test for non-matching HAL versions am: 248708f63c am: 8c32e628be
Change-Id: I0a8f39516c94336a63c7648a27db135229fadf8d
Diffstat (limited to 'audio')
-rw-r--r--audio/effect/all-versions/vts/functional/ValidateAudioEffectsConfiguration.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/audio/effect/all-versions/vts/functional/ValidateAudioEffectsConfiguration.cpp b/audio/effect/all-versions/vts/functional/ValidateAudioEffectsConfiguration.cpp
index f9e4aa30eb..9c0135bf93 100644
--- a/audio/effect/all-versions/vts/functional/ValidateAudioEffectsConfiguration.cpp
+++ b/audio/effect/all-versions/vts/functional/ValidateAudioEffectsConfiguration.cpp
@@ -18,6 +18,12 @@
#include <iterator>
#include <media/EffectsConfig.h>
+// clang-format off
+#include PATH(android/hardware/audio/effect/FILE_VERSION/IEffectsFactory.h)
+// clang-format on
+
+#include <gtest/gtest.h>
+#include <hidl/ServiceManagement.h>
#include "utility/ValidateXml.h"
@@ -29,6 +35,11 @@ TEST(CheckConfig, audioEffectsConfigurationValidation) {
RecordProperty("description",
"Verify that the effects configuration file is valid according to the schema");
using namespace android::effectsConfig;
+ if (android::hardware::getAllHalInstanceNames(
+ ::android::hardware::audio::effect::CPP_VERSION::IEffectsFactory::descriptor)
+ .size() == 0) {
+ GTEST_SKIP() << "No Effects HAL version " STRINGIFY(CPP_VERSION) " on this device";
+ }
std::vector<const char*> locations(std::begin(DEFAULT_LOCATIONS), std::end(DEFAULT_LOCATIONS));
const char* xsd = "/data/local/tmp/audio_effects_conf_" STRINGIFY(CPP_VERSION) ".xsd";