summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2024-01-31 22:59:03 +0000
committerAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2024-01-31 22:59:03 +0000
commit2a1d40e96ab15db871339918e6c1f68def3f6ddb (patch)
tree85203f15331f60b39cd47f0285be575771bffbe1
parent158850357e145feef048f03687d92cfd1e5d2233 (diff)
parent8274e824f52d6a01f785ff6f0052db4cc8c3c3ed (diff)
downloadinterfaces-aml_cbr_341610000.tar.gz
Snap for 11383711 from 8274e824f52d6a01f785ff6f0052db4cc8c3c3ed to mainline-cellbroadcast-releaseaml_cbr_341610000
Change-Id: Ibb16a1e8d4d7975c7e39e91ca1db093ce63377d4
-rw-r--r--automotive/evs/1.1/vts/functional/VtsHalEvsV1_1TargetTest.cpp7
-rw-r--r--automotive/vehicle/vts/src/VtsHalAutomotiveVehicle_TargetTest.cpp95
-rw-r--r--camera/provider/aidl/vts/camera_aidl_test.cpp39
-rw-r--r--camera/provider/aidl/vts/camera_aidl_test.h3
-rw-r--r--light/aidl/aidl_api/android.hardware.light/2/.hash1
-rw-r--r--light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLight.aidl2
-rw-r--r--light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLightState.aidl2
-rw-r--r--light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLight.aidl2
-rw-r--r--light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLightState.aidl2
-rw-r--r--light/aidl/android/hardware/light/HwLight.aidl2
-rw-r--r--light/aidl/android/hardware/light/HwLightState.aidl2
-rw-r--r--nfc/1.0/vts/functional/VtsHalNfcV1_0TargetTest.cpp13
-rw-r--r--radio/aidl/vts/radio_network_test.cpp6
-rw-r--r--secure_element/aidl/vts/AndroidTest.xml33
-rw-r--r--tv/tuner/aidl/vts/functional/VtsHalTvTunerTestConfigurations.h17
-rw-r--r--wifi/aidl/vts/functional/wifi_sta_iface_aidl_test.cpp17
16 files changed, 182 insertions, 61 deletions
diff --git a/automotive/evs/1.1/vts/functional/VtsHalEvsV1_1TargetTest.cpp b/automotive/evs/1.1/vts/functional/VtsHalEvsV1_1TargetTest.cpp
index 03f256ec81..ff7f41c119 100644
--- a/automotive/evs/1.1/vts/functional/VtsHalEvsV1_1TargetTest.cpp
+++ b/automotive/evs/1.1/vts/functional/VtsHalEvsV1_1TargetTest.cpp
@@ -2010,6 +2010,13 @@ TEST_P(EvsHidlTest, CameraUseStreamConfigToDisplay) {
// Test each reported camera
for (auto&& cam: cameraInfo) {
+ bool isLogicalCam = false;
+ getPhysicalCameraIds(cam.v1.cameraId, isLogicalCam);
+ if (isLogicalCam) {
+ LOG(INFO) << "Skip a logical device " << cam.v1.cameraId;
+ continue;
+ }
+
// Request exclusive access to the EVS display
sp<IEvsDisplay_1_0> pDisplay = pEnumerator->openDisplay();
ASSERT_NE(pDisplay, nullptr);
diff --git a/automotive/vehicle/vts/src/VtsHalAutomotiveVehicle_TargetTest.cpp b/automotive/vehicle/vts/src/VtsHalAutomotiveVehicle_TargetTest.cpp
index 737be847ed..1c528864b8 100644
--- a/automotive/vehicle/vts/src/VtsHalAutomotiveVehicle_TargetTest.cpp
+++ b/automotive/vehicle/vts/src/VtsHalAutomotiveVehicle_TargetTest.cpp
@@ -25,6 +25,7 @@
#include <android-base/stringprintf.h>
#include <android-base/thread_annotations.h>
#include <android/binder_process.h>
+#include <android/hardware/automotive/vehicle/2.0/IVehicle.h>
#include <gtest/gtest.h>
#include <hidl/GtestPrinter.h>
#include <hidl/ServiceManagement.h>
@@ -34,20 +35,22 @@
#include <chrono>
#include <mutex>
+#include <thread>
#include <unordered_map>
#include <unordered_set>
#include <vector>
using ::aidl::android::hardware::automotive::vehicle::IVehicle;
-using ::aidl::android::hardware::automotive::vehicle::StatusCode;
using ::aidl::android::hardware::automotive::vehicle::SubscribeOptions;
using ::aidl::android::hardware::automotive::vehicle::VehicleArea;
using ::aidl::android::hardware::automotive::vehicle::VehicleProperty;
using ::aidl::android::hardware::automotive::vehicle::VehiclePropertyAccess;
using ::aidl::android::hardware::automotive::vehicle::VehiclePropertyChangeMode;
using ::aidl::android::hardware::automotive::vehicle::VehiclePropertyGroup;
+using ::aidl::android::hardware::automotive::vehicle::VehiclePropertyStatus;
using ::aidl::android::hardware::automotive::vehicle::VehiclePropertyType;
using ::android::getAidlHalInstanceNames;
+using ::android::uptimeMillis;
using ::android::base::ScopedLockAssertion;
using ::android::base::StringPrintf;
using ::android::frameworks::automotive::vhal::ErrorCode;
@@ -56,11 +59,14 @@ using ::android::frameworks::automotive::vhal::IHalPropConfig;
using ::android::frameworks::automotive::vhal::IHalPropValue;
using ::android::frameworks::automotive::vhal::ISubscriptionCallback;
using ::android::frameworks::automotive::vhal::IVhalClient;
+using ::android::frameworks::automotive::vhal::VhalClientResult;
using ::android::hardware::getAllHalInstanceNames;
using ::android::hardware::Sanitize;
using ::android::hardware::automotive::vehicle::toInt;
constexpr int32_t kInvalidProp = 0x31600207;
+// The timeout for retrying getting prop value after setting prop value.
+constexpr int64_t kRetryGetPropAfterSetPropTimeoutMillis = 10'000;
struct ServiceDescriptor {
std::string name;
@@ -117,6 +123,10 @@ class VtsVehicleCallback final : public ISubscriptionCallback {
class VtsHalAutomotiveVehicleTargetTest : public testing::TestWithParam<ServiceDescriptor> {
protected:
bool checkIsSupported(int32_t propertyId);
+ VehiclePropertyStatus getStatus(const IHalPropValue& halPropValue);
+ bool isUnavailable(const VhalClientResult<std::unique_ptr<IHalPropValue>>& result);
+ bool isResultOkayWithValue(const VhalClientResult<std::unique_ptr<IHalPropValue>>& result,
+ int32_t value);
public:
void verifyProperty(VehicleProperty propId, VehiclePropertyAccess access,
@@ -230,6 +240,41 @@ TEST_P(VtsHalAutomotiveVehicleTargetTest, getInvalidProp) {
"Expect failure to get property for invalid prop: %" PRId32, kInvalidProp);
}
+VehiclePropertyStatus VtsHalAutomotiveVehicleTargetTest::getStatus(
+ const IHalPropValue& halPropValue) {
+ if (mVhalClient->isAidlVhal()) {
+ return reinterpret_cast<
+ const aidl::android::hardware::automotive::vehicle::VehiclePropValue*>(
+ halPropValue.toVehiclePropValue())
+ ->status;
+ }
+ return static_cast<VehiclePropertyStatus>(
+ reinterpret_cast<const android::hardware::automotive::vehicle::V2_0::VehiclePropValue*>(
+ halPropValue.toVehiclePropValue())
+ ->status);
+}
+
+bool VtsHalAutomotiveVehicleTargetTest::isResultOkayWithValue(
+ const VhalClientResult<std::unique_ptr<IHalPropValue>>& result, int32_t value) {
+ return result.ok() && result.value() != nullptr &&
+ getStatus(*(result.value())) == VehiclePropertyStatus::AVAILABLE &&
+ result.value()->getInt32Values().size() == 1 &&
+ result.value()->getInt32Values()[0] == value;
+}
+
+bool VtsHalAutomotiveVehicleTargetTest::isUnavailable(
+ const VhalClientResult<std::unique_ptr<IHalPropValue>>& result) {
+ if (!result.ok()) {
+ return result.error().code() == ErrorCode::NOT_AVAILABLE_FROM_VHAL;
+ }
+ if (result.value() != nullptr &&
+ getStatus(*(result.value())) == VehiclePropertyStatus::UNAVAILABLE) {
+ return true;
+ }
+
+ return false;
+}
+
// Test set() on read_write properties.
TEST_P(VtsHalAutomotiveVehicleTargetTest, setProp) {
ALOGD("VtsHalAutomotiveVehicleTargetTest::setProp");
@@ -257,6 +302,14 @@ TEST_P(VtsHalAutomotiveVehicleTargetTest, setProp) {
auto propToGet = mVhalClient->createHalPropValue(propId);
auto getValueResult = mVhalClient->getValueSync(*propToGet);
+ if (isUnavailable(getValueResult)) {
+ ALOGW("getProperty for %" PRId32
+ " returns NOT_AVAILABLE, "
+ "skip testing setProp",
+ propId);
+ return;
+ }
+
ASSERT_TRUE(getValueResult.ok())
<< StringPrintf("Failed to get value for property: %" PRId32 ", error: %s",
propId, getValueResult.error().message().c_str());
@@ -269,17 +322,48 @@ TEST_P(VtsHalAutomotiveVehicleTargetTest, setProp) {
"Expect exactly 1 int value for boolean property: %" PRId32 ", got %zu", propId,
intValueSize);
- int setValue = value.getInt32Values()[0] == 1 ? 0 : 1;
+ int32_t setValue = value.getInt32Values()[0] == 1 ? 0 : 1;
auto propToSet = mVhalClient->createHalPropValue(propId);
propToSet->setInt32Values({setValue});
auto setValueResult = mVhalClient->setValueSync(*propToSet);
+ if (!setValueResult.ok() &&
+ setValueResult.error().code() == ErrorCode::NOT_AVAILABLE_FROM_VHAL) {
+ ALOGW("setProperty for %" PRId32
+ " returns NOT_AVAILABLE, "
+ "skip verifying getProperty returns the same value",
+ propId);
+ return;
+ }
+
ASSERT_TRUE(setValueResult.ok())
<< StringPrintf("Failed to set value for property: %" PRId32 ", error: %s",
propId, setValueResult.error().message().c_str());
+ // Retry getting the value until we pass the timeout. getValue might not return
+ // the expected value immediately since setValue is async.
+ auto timeoutMillis = uptimeMillis() + kRetryGetPropAfterSetPropTimeoutMillis;
+
+ while (true) {
+ getValueResult = mVhalClient->getValueSync(*propToGet);
+ if (isResultOkayWithValue(getValueResult, setValue)) {
+ break;
+ }
+ if (uptimeMillis() >= timeoutMillis) {
+ // Reach timeout, the following assert should fail.
+ break;
+ }
+ // Sleep for 100ms between each getValueSync retry.
+ std::this_thread::sleep_for(std::chrono::milliseconds(100));
+ }
+
+ if (isUnavailable(getValueResult)) {
+ ALOGW("getProperty for %" PRId32
+ " returns NOT_AVAILABLE, "
+ "skip verifying the return value",
+ propId);
+ return;
+ }
- // check set success
- getValueResult = mVhalClient->getValueSync(*propToGet);
ASSERT_TRUE(getValueResult.ok())
<< StringPrintf("Failed to get value for property: %" PRId32 ", error: %s",
propId, getValueResult.error().message().c_str());
@@ -900,7 +984,8 @@ std::vector<ServiceDescriptor> getDescriptors() {
.isAidlService = true,
});
}
- for (std::string name : getAllHalInstanceNames(IVehicle::descriptor)) {
+ for (std::string name : getAllHalInstanceNames(
+ android::hardware::automotive::vehicle::V2_0::IVehicle::descriptor)) {
descriptors.push_back({
.name = name,
.isAidlService = false,
diff --git a/camera/provider/aidl/vts/camera_aidl_test.cpp b/camera/provider/aidl/vts/camera_aidl_test.cpp
index 5f9d605ef3..9559a1e965 100644
--- a/camera/provider/aidl/vts/camera_aidl_test.cpp
+++ b/camera/provider/aidl/vts/camera_aidl_test.cpp
@@ -310,21 +310,11 @@ void CameraAidlTest::verifyMonochromeCameraResult(
void CameraAidlTest::verifyStreamUseCaseCharacteristics(const camera_metadata_t* metadata) {
camera_metadata_ro_entry entry;
- // Check capabilities
- int retcode =
- find_camera_metadata_ro_entry(metadata, ANDROID_REQUEST_AVAILABLE_CAPABILITIES, &entry);
- bool hasStreamUseCaseCap = false;
- if ((0 == retcode) && (entry.count > 0)) {
- if (std::find(entry.data.u8, entry.data.u8 + entry.count,
- ANDROID_REQUEST_AVAILABLE_CAPABILITIES_STREAM_USE_CASE) !=
- entry.data.u8 + entry.count) {
- hasStreamUseCaseCap = true;
- }
- }
+ bool hasStreamUseCaseCap = supportsStreamUseCaseCap(metadata);
bool supportMandatoryUseCases = false;
- retcode = find_camera_metadata_ro_entry(metadata, ANDROID_SCALER_AVAILABLE_STREAM_USE_CASES,
- &entry);
+ int retcode = find_camera_metadata_ro_entry(metadata, ANDROID_SCALER_AVAILABLE_STREAM_USE_CASES,
+ &entry);
if ((0 == retcode) && (entry.count > 0)) {
supportMandatoryUseCases = true;
for (size_t i = 0; i < kMandatoryUseCases.size(); i++) {
@@ -2195,10 +2185,10 @@ void CameraAidlTest::configureStreamUseCaseInternal(const AvailableStream &thres
&cameraDevice /*out*/);
camera_metadata_t* staticMeta = reinterpret_cast<camera_metadata_t*>(meta.metadata.data());
- // Check if camera support depth only
- if (isDepthOnly(staticMeta) ||
- (threshold.format == static_cast<int32_t>(PixelFormat::RAW16) &&
- !supportsCroppedRawUseCase(staticMeta))) {
+ // Check if camera support depth only or doesn't support stream use case capability
+ if (isDepthOnly(staticMeta) || !supportsStreamUseCaseCap(staticMeta) ||
+ (threshold.format == static_cast<int32_t>(PixelFormat::RAW16) &&
+ !supportsCroppedRawUseCase(staticMeta))) {
ndk::ScopedAStatus ret = mSession->close();
mSession = nullptr;
ASSERT_TRUE(ret.isOk());
@@ -3212,6 +3202,21 @@ bool CameraAidlTest::supportsCroppedRawUseCase(const camera_metadata_t *staticMe
return false;
}
+bool CameraAidlTest::supportsStreamUseCaseCap(const camera_metadata_t* staticMeta) {
+ camera_metadata_ro_entry entry;
+ int retcode = find_camera_metadata_ro_entry(staticMeta, ANDROID_REQUEST_AVAILABLE_CAPABILITIES,
+ &entry);
+ bool hasStreamUseCaseCap = false;
+ if ((0 == retcode) && (entry.count > 0)) {
+ if (std::find(entry.data.u8, entry.data.u8 + entry.count,
+ ANDROID_REQUEST_AVAILABLE_CAPABILITIES_STREAM_USE_CASE) !=
+ entry.data.u8 + entry.count) {
+ hasStreamUseCaseCap = true;
+ }
+ }
+ return hasStreamUseCaseCap;
+}
+
bool CameraAidlTest::isPerFrameControl(const camera_metadata_t* staticMeta) {
camera_metadata_ro_entry syncLatencyEntry;
int rc = find_camera_metadata_ro_entry(staticMeta, ANDROID_SYNC_MAX_LATENCY,
diff --git a/camera/provider/aidl/vts/camera_aidl_test.h b/camera/provider/aidl/vts/camera_aidl_test.h
index 6f8f380fa4..fa21a06e84 100644
--- a/camera/provider/aidl/vts/camera_aidl_test.h
+++ b/camera/provider/aidl/vts/camera_aidl_test.h
@@ -415,7 +415,8 @@ class CameraAidlTest : public ::testing::TestWithParam<std::string> {
int32_t frameCount, const bool *overrideSequence, const bool *expectedResults);
bool supportZoomSettingsOverride(const camera_metadata_t* staticMeta);
- bool supportsCroppedRawUseCase(const camera_metadata_t *staticMeta);
+ static bool supportsStreamUseCaseCap(const camera_metadata_t* staticMeta);
+ static bool supportsCroppedRawUseCase(const camera_metadata_t* staticMeta);
bool isPerFrameControl(const camera_metadata_t* staticMeta);
void getSupportedSizes(const camera_metadata_t* ch, uint32_t tag, int32_t format,
diff --git a/light/aidl/aidl_api/android.hardware.light/2/.hash b/light/aidl/aidl_api/android.hardware.light/2/.hash
index d27f4ad9d4..2d4e7f0a65 100644
--- a/light/aidl/aidl_api/android.hardware.light/2/.hash
+++ b/light/aidl/aidl_api/android.hardware.light/2/.hash
@@ -1 +1,2 @@
c8b1e8ebb88c57dcb2c350a8d9b722e77dd864c8
+c7d3d941d303c70d1c22759a0b09e41930c1cddb
diff --git a/light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLight.aidl b/light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLight.aidl
index 25a2dce37d..5ac2a34305 100644
--- a/light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLight.aidl
+++ b/light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLight.aidl
@@ -32,7 +32,7 @@
// later when a module using the interface is updated, e.g., Mainline modules.
package android.hardware.light;
-@VintfStability
+@RustDerive(Clone=true, Copy=true) @VintfStability
parcelable HwLight {
int id;
int ordinal;
diff --git a/light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLightState.aidl b/light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLightState.aidl
index 40e520b796..2878ce256f 100644
--- a/light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLightState.aidl
+++ b/light/aidl/aidl_api/android.hardware.light/2/android/hardware/light/HwLightState.aidl
@@ -32,7 +32,7 @@
// later when a module using the interface is updated, e.g., Mainline modules.
package android.hardware.light;
-@VintfStability
+@RustDerive(Clone=true, Copy=true) @VintfStability
parcelable HwLightState {
int color;
android.hardware.light.FlashMode flashMode;
diff --git a/light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLight.aidl b/light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLight.aidl
index 25a2dce37d..5ac2a34305 100644
--- a/light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLight.aidl
+++ b/light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLight.aidl
@@ -32,7 +32,7 @@
// later when a module using the interface is updated, e.g., Mainline modules.
package android.hardware.light;
-@VintfStability
+@RustDerive(Clone=true, Copy=true) @VintfStability
parcelable HwLight {
int id;
int ordinal;
diff --git a/light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLightState.aidl b/light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLightState.aidl
index 40e520b796..2878ce256f 100644
--- a/light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLightState.aidl
+++ b/light/aidl/aidl_api/android.hardware.light/current/android/hardware/light/HwLightState.aidl
@@ -32,7 +32,7 @@
// later when a module using the interface is updated, e.g., Mainline modules.
package android.hardware.light;
-@VintfStability
+@RustDerive(Clone=true, Copy=true) @VintfStability
parcelable HwLightState {
int color;
android.hardware.light.FlashMode flashMode;
diff --git a/light/aidl/android/hardware/light/HwLight.aidl b/light/aidl/android/hardware/light/HwLight.aidl
index 43fdb4bf81..8db32cc043 100644
--- a/light/aidl/android/hardware/light/HwLight.aidl
+++ b/light/aidl/android/hardware/light/HwLight.aidl
@@ -22,7 +22,7 @@ import android.hardware.light.LightType;
* A description of a single light. Multiple lights can map to the same physical
* LED. Separate physical LEDs are always represented by separate instances.
*/
-@VintfStability
+@RustDerive(Clone=true, Copy=true) @VintfStability
parcelable HwLight {
/**
* Integer ID used for controlling this light
diff --git a/light/aidl/android/hardware/light/HwLightState.aidl b/light/aidl/android/hardware/light/HwLightState.aidl
index 24d3250887..3ba6c7874c 100644
--- a/light/aidl/android/hardware/light/HwLightState.aidl
+++ b/light/aidl/android/hardware/light/HwLightState.aidl
@@ -25,7 +25,7 @@ import android.hardware.light.FlashMode;
* Not all lights must support all parameters. If you
* can do something backward-compatible, do it.
*/
-@VintfStability
+@RustDerive(Clone=true, Copy=true) @VintfStability
parcelable HwLightState {
/**
* The color of the LED in ARGB.
diff --git a/nfc/1.0/vts/functional/VtsHalNfcV1_0TargetTest.cpp b/nfc/1.0/vts/functional/VtsHalNfcV1_0TargetTest.cpp
index 4d997e6569..8210ff04cf 100644
--- a/nfc/1.0/vts/functional/VtsHalNfcV1_0TargetTest.cpp
+++ b/nfc/1.0/vts/functional/VtsHalNfcV1_0TargetTest.cpp
@@ -296,12 +296,6 @@ TEST_P(NfcHidlTest, WriteInvalidAndThenValidCommand) {
res = nfc_cb_->WaitForCallback(kCallbackNameSendData);
EXPECT_TRUE(res.no_timeout);
EXPECT_EQ((int)NfcStatus::OK, res.args->last_data_[3]);
- if (nci_version == NCI_VERSION_2 && res.args->last_data_.size() > 13 &&
- res.args->last_data_[13] == 0x00) {
- // Wait for CORE_CONN_CREDITS_NTF
- res = nfc_cb_->WaitForCallback(kCallbackNameSendData);
- EXPECT_TRUE(res.no_timeout);
- }
// Send an Error Data Packet
cmd = INVALID_COMMAND;
data = cmd;
@@ -360,13 +354,6 @@ TEST_P(NfcHidlTest, Bandwidth) {
res = nfc_cb_->WaitForCallback(kCallbackNameSendData);
EXPECT_TRUE(res.no_timeout);
EXPECT_EQ((int)NfcStatus::OK, res.args->last_data_[3]);
- if (nci_version == NCI_VERSION_2 && res.args->last_data_.size() > 13 &&
- res.args->last_data_[13] == 0x00) {
- // Wait for CORE_CONN_CREDITS_NTF
- res = nfc_cb_->WaitForCallback(kCallbackNameSendData);
- EXPECT_TRUE(res.no_timeout);
- }
-
cmd = CORE_CONN_CREATE_CMD;
data = cmd;
EXPECT_EQ(data.size(), nfc_->write(data));
diff --git a/radio/aidl/vts/radio_network_test.cpp b/radio/aidl/vts/radio_network_test.cpp
index 6643c1e7ff..f316a34554 100644
--- a/radio/aidl/vts/radio_network_test.cpp
+++ b/radio/aidl/vts/radio_network_test.cpp
@@ -733,7 +733,7 @@ TEST_P(RadioNetworkTest, setLinkCapacityReportingCriteria_invalidHysteresisDlKbp
ALOGI("setLinkCapacityReportingCriteria_invalidHysteresisDlKbps, rspInfo.error = %s\n",
toString(radioRsp_network->rspInfo.error).c_str());
- ASSERT_TRUE(CheckAnyOfErrors(radioRsp_network->rspInfo.error, {RadioError::INVALID_ARGUMENTS}));
+ ASSERT_TRUE(CheckAnyOfErrors(radioRsp_network->rspInfo.error, {RadioError::INVALID_ARGUMENTS, RadioError::REQUEST_NOT_SUPPORTED}));
}
/*
@@ -752,7 +752,7 @@ TEST_P(RadioNetworkTest, setLinkCapacityReportingCriteria_invalidHysteresisUlKbp
ALOGI("setLinkCapacityReportingCriteria_invalidHysteresisUlKbps, rspInfo.error = %s\n",
toString(radioRsp_network->rspInfo.error).c_str());
- ASSERT_TRUE(CheckAnyOfErrors(radioRsp_network->rspInfo.error, {RadioError::INVALID_ARGUMENTS}));
+ ASSERT_TRUE(CheckAnyOfErrors(radioRsp_network->rspInfo.error, {RadioError::INVALID_ARGUMENTS, RadioError::REQUEST_NOT_SUPPORTED}));
}
/*
@@ -770,7 +770,7 @@ TEST_P(RadioNetworkTest, setLinkCapacityReportingCriteria_emptyParams) {
ALOGI("setLinkCapacityReportingCriteria_emptyParams, rspInfo.error = %s\n",
toString(radioRsp_network->rspInfo.error).c_str());
- ASSERT_TRUE(CheckAnyOfErrors(radioRsp_network->rspInfo.error, {RadioError::NONE}));
+ ASSERT_TRUE(CheckAnyOfErrors(radioRsp_network->rspInfo.error, {RadioError::NONE, RadioError::REQUEST_NOT_SUPPORTED}));
}
/*
diff --git a/secure_element/aidl/vts/AndroidTest.xml b/secure_element/aidl/vts/AndroidTest.xml
new file mode 100644
index 0000000000..94dfa8290a
--- /dev/null
+++ b/secure_element/aidl/vts/AndroidTest.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2024 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<configuration description="Runs VtsHalSecureElementTargetTest.">
+ <option name="test-suite-tag" value="apct" />
+ <option name="test-suite-tag" value="apct-native" />
+ <option name="config-descriptor:metadata" key="token" value="SECURE_ELEMENT_SIM_CARD" />
+
+ <target_preparer class="com.android.tradefed.targetprep.RootTargetPreparer">
+ </target_preparer>
+
+ <target_preparer class="com.android.tradefed.targetprep.PushFilePreparer">
+ <option name="cleanup" value="true" />
+ <option name="push" value="VtsHalSecureElementTargetTest->/data/local/tmp/VtsHalSecureElementTargetTest" />
+ </target_preparer>
+
+ <test class="com.android.tradefed.testtype.GTest" >
+ <option name="native-test-device-path" value="/data/local/tmp" />
+ <option name="module-name" value="VtsHalSecureElementTargetTest" />
+ </test>
+</configuration>
diff --git a/tv/tuner/aidl/vts/functional/VtsHalTvTunerTestConfigurations.h b/tv/tuner/aidl/vts/functional/VtsHalTvTunerTestConfigurations.h
index 5c13ed081a..ff94639466 100644
--- a/tv/tuner/aidl/vts/functional/VtsHalTvTunerTestConfigurations.h
+++ b/tv/tuner/aidl/vts/functional/VtsHalTvTunerTestConfigurations.h
@@ -731,9 +731,20 @@ inline void determineLive() {
if (videoFilterIds.empty() || audioFilterIds.empty() || frontendMap.empty()) {
return;
}
- if (hasSwFe && !hasHwFe && dvrMap.empty()) {
- ALOGD("Cannot configure Live. Only software frontends and no dvr connections");
- return;
+ if (!hasHwFe) {
+ if (hasSwFe) {
+ if (dvrMap.empty()) {
+ ALOGD("Cannot configure Live. Only software frontends and no dvr connections.");
+ return;
+ }
+ // Live is available if there is SW FE and some DVR is attached.
+ } else {
+ // We will arrive here because frontendMap won't be empty since
+ // there will be at least a default frontend declared. But the
+ // default frontend doesn't count as "hasSwFe".
+ ALOGD("Cannot configure Live. No frontend declared at all.");
+ return;
+ }
}
ALOGD("Can support live");
live.hasFrontendConnection = true;
diff --git a/wifi/aidl/vts/functional/wifi_sta_iface_aidl_test.cpp b/wifi/aidl/vts/functional/wifi_sta_iface_aidl_test.cpp
index 1ea1237a2d..fa7149ff55 100644
--- a/wifi/aidl/vts/functional/wifi_sta_iface_aidl_test.cpp
+++ b/wifi/aidl/vts/functional/wifi_sta_iface_aidl_test.cpp
@@ -69,18 +69,9 @@ class WifiStaIfaceAidlTest : public testing::TestWithParam<std::string> {
std::shared_ptr<IWifiStaIface> wifi_sta_iface_;
- // Checks if the MdnsOffloadManagerService is installed.
- bool isMdnsOffloadServicePresent() {
- int status =
- // --query-flags MATCH_SYSTEM_ONLY(1048576) will only return matched service
- // installed on system or system_ext partition. The MdnsOffloadManagerService should
- // be installed on system_ext partition.
- // NOLINTNEXTLINE(cert-env33-c)
- system("pm query-services --query-flags 1048576"
- " com.android.tv.mdnsoffloadmanager/"
- "com.android.tv.mdnsoffloadmanager.MdnsOffloadManagerService"
- " | egrep -q mdnsoffloadmanager");
- return status == 0;
+ // Checks if the mDNS Offload is supported by any NIC.
+ bool isMdnsOffloadPresentInNIC() {
+ return testing::deviceSupportsFeature("com.google.android.tv.mdns_offload");
}
// Detected panel TV device by using ro.oem.key1 property.
@@ -146,7 +137,7 @@ TEST_P(WifiStaIfaceAidlTest, GetFeatureSet) {
TEST_P(WifiStaIfaceAidlTest, CheckApfIsSupported) {
// Flat panel TV devices that support MDNS offload do not have to implement APF if the WiFi
// chipset does not have sufficient RAM to do so.
- if (isPanelTvDevice() && isMdnsOffloadServicePresent()) {
+ if (isPanelTvDevice() && isMdnsOffloadPresentInNIC()) {
GTEST_SKIP() << "Panel TV supports mDNS offload. It is not required to support APF";
}
int vendor_api_level = property_get_int32("ro.vendor.api_level", 0);