summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTreehugger Robot <android-test-infra-autosubmit@system.gserviceaccount.com>2024-02-22 01:04:39 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2024-02-22 01:04:39 +0000
commit177886c9fe9efc27fb9d84eda3f505b377644d79 (patch)
tree8b8dabbf2ecc89691b98a01073169b2107842a76
parente1f30fedcc9aa39848b2a645fe1cca49d76a6dac (diff)
parentf0374167d4f63c06086332e9620e27c861871415 (diff)
downloadav-177886c9fe9efc27fb9d84eda3f505b377644d79.tar.gz
Merge "VTS: enforce AIDL for media.c2" into main
-rw-r--r--media/codec2/hal/hidl/1.0/vts/functional/master/VtsHalMediaC2V1_0TargetMasterTest.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/media/codec2/hal/hidl/1.0/vts/functional/master/VtsHalMediaC2V1_0TargetMasterTest.cpp b/media/codec2/hal/hidl/1.0/vts/functional/master/VtsHalMediaC2V1_0TargetMasterTest.cpp
index 47ceed5841..a34cef1c13 100644
--- a/media/codec2/hal/hidl/1.0/vts/functional/master/VtsHalMediaC2V1_0TargetMasterTest.cpp
+++ b/media/codec2/hal/hidl/1.0/vts/functional/master/VtsHalMediaC2V1_0TargetMasterTest.cpp
@@ -18,6 +18,7 @@
#define LOG_TAG "codec2_hidl_hal_master_test"
#include <android-base/logging.h>
+#include <android-base/properties.h>
#include <gtest/gtest.h>
#include <hidl/GtestPrinter.h>
#include <hidl/ServiceManagement.h>
@@ -82,6 +83,20 @@ TEST_P(Codec2MasterHalTest, ListComponents) {
}
}
+TEST_P(Codec2MasterHalTest, MustUseAidlBeyond202404) {
+ static int sBoardFirstApiLevel = android::base::GetIntProperty("ro.board.first_api_level", 0);
+ static int sBoardApiLevel = android::base::GetIntProperty("ro.board.api_level", 0);
+ if (sBoardFirstApiLevel < 202404 && sBoardApiLevel < 202404) {
+ GTEST_SKIP() << "board first level less than 202404:"
+ << " ro.board.first_api_level = " << sBoardFirstApiLevel
+ << " ro.board.api_level = " << sBoardApiLevel;
+ }
+ ALOGV("HidlCodecAllowed Test");
+
+ EXPECT_NE(mClient->getAidlBase(), nullptr) << "android.hardware.media.c2 MUST use AIDL "
+ << "for chipsets launching at 202404 or above";
+}
+
} // anonymous namespace
INSTANTIATE_TEST_SUITE_P(PerInstance, Codec2MasterHalTest,