Fixing logging in Vehicle HAL, code clean up
Test: this just refactoring, verified existing tests still passing
Change-Id: I70ad3928f9fe6b2f6c677b4d6848f263f3c25d11
Fix: b/33297409
diff --git a/vehicle/2.0/default/tests/VehicleHalTestUtils.h b/vehicle/2.0/default/tests/VehicleHalTestUtils.h
index 16d0be9..586b5ab 100644
--- a/vehicle/2.0/default/tests/VehicleHalTestUtils.h
+++ b/vehicle/2.0/default/tests/VehicleHalTestUtils.h
@@ -43,17 +43,17 @@
.permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = static_cast<int32_t>(
VehicleAreaZone::ROW_1_LEFT | VehicleAreaZone::ROW_1_RIGHT),
- .areaConfigs = init_hidl_vec({
- VehicleAreaConfig {
- .areaId = toInt(VehicleAreaZone::ROW_1_LEFT),
- .minInt32Value = 1,
- .maxInt32Value = 7},
- VehicleAreaConfig {
- .areaId = toInt(VehicleAreaZone::ROW_1_RIGHT),
- .minInt32Value = 1,
- .maxInt32Value = 5,
- }
- }),
+ .areaConfigs = {
+ VehicleAreaConfig {
+ .areaId = toInt(VehicleAreaZone::ROW_1_LEFT),
+ .minInt32Value = 1,
+ .maxInt32Value = 7},
+ VehicleAreaConfig {
+ .areaId = toInt(VehicleAreaZone::ROW_1_RIGHT),
+ .minInt32Value = 1,
+ .maxInt32Value = 5,
+ }
+ }
},
// Write-only property
@@ -64,17 +64,17 @@
.permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = static_cast<int32_t>(
VehicleAreaZone::ROW_1_LEFT | VehicleAreaZone::ROW_1_RIGHT),
- .areaConfigs = init_hidl_vec({
- VehicleAreaConfig {
- .areaId = toInt(VehicleAreaZone::ROW_1_LEFT),
- .minInt32Value = 64,
- .maxInt32Value = 80},
- VehicleAreaConfig {
- .areaId = toInt(VehicleAreaZone::ROW_1_RIGHT),
- .minInt32Value = 64,
- .maxInt32Value = 80,
- }
- }),
+ .areaConfigs = {
+ VehicleAreaConfig {
+ .areaId = toInt(VehicleAreaZone::ROW_1_LEFT),
+ .minInt32Value = 64,
+ .maxInt32Value = 80},
+ VehicleAreaConfig {
+ .areaId = toInt(VehicleAreaZone::ROW_1_RIGHT),
+ .minInt32Value = 64,
+ .maxInt32Value = 80,
+ }
+ }
},
{
@@ -82,12 +82,12 @@
.access = VehiclePropertyAccess::READ,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
.permissionModel = VehiclePermissionModel::OEM_ONLY,
- .areaConfigs = init_hidl_vec({
- VehicleAreaConfig {
- .minFloatValue = 0,
- .maxFloatValue = 1.0
- }
- })
+ .areaConfigs = {
+ VehicleAreaConfig {
+ .minFloatValue = 0,
+ .maxFloatValue = 1.0
+ }
+ }
},
{
@@ -95,12 +95,12 @@
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
.permissionModel = VehiclePermissionModel::OEM_ONLY,
- .areaConfigs = init_hidl_vec({
- VehicleAreaConfig {
- .minInt32Value = 0,
- .maxInt32Value = 10
- }
- })
+ .areaConfigs = {
+ VehicleAreaConfig {
+ .minInt32Value = 0,
+ .maxInt32Value = 10
+ }
+ }
},
{