Skip to content

Commit 6f3a83e

Browse files
kkasperczyk-norlubos
authored andcommitted
[nrf noup] Removed configuration-version from attribute list
Added workaround that removed provisional configuration-version from attribute list. Signed-off-by: Kamil Kasperczyk <[email protected]>
1 parent ffe3f85 commit 6f3a83e

File tree

2 files changed

+12
-18
lines changed

2 files changed

+12
-18
lines changed

src/app/clusters/basic-information/BasicInformationCluster.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,10 @@ constexpr DataModel::AttributeEntry kMandatoryAttributes[] = {
6666
CapabilityMinima::kMetadataEntry,
6767
SpecificationVersion::kMetadataEntry,
6868
MaxPathsPerInvoke::kMetadataEntry,
69-
ConfigurationVersion::kMetadataEntry,
69+
// WORKAROUND: The ConfigurationVersion attribute is marked as mandatory and cannot be disabled, but it is provisional and
70+
// should not be used.
71+
// TODO: Remove this workaround when the ConfigurationVersion attribute is no longer provisional.
72+
// ConfigurationVersion::kMetadataEntry,
7073
// NOTE: UniqueID used to NOT be mandatory in previous spec version, so we add
7174
// this as a separate condition
7275
// UniqueID::kMetadataEntry,

src/app/clusters/basic-information/tests/TestBasicInformationCluster.cpp

Lines changed: 8 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ TEST_F(TestBasicInformationCluster, TestAttributes)
7272
ProductName::kMetadataEntry, ProductID::kMetadataEntry, NodeLabel::kMetadataEntry, Location::kMetadataEntry,
7373
HardwareVersion::kMetadataEntry, HardwareVersionString::kMetadataEntry, SoftwareVersion::kMetadataEntry,
7474
SoftwareVersionString::kMetadataEntry, CapabilityMinima::kMetadataEntry, SpecificationVersion::kMetadataEntry,
75-
MaxPathsPerInvoke::kMetadataEntry, ConfigurationVersion::kMetadataEntry,
76-
UniqueID::kMetadataEntry, // required in latest spec
75+
MaxPathsPerInvoke::kMetadataEntry, // ConfigurationVersion::kMetadataEntry,
76+
UniqueID::kMetadataEntry, // required in latest spec
7777
}),
7878
CHIP_NO_ERROR);
7979
ASSERT_EQ(expectedBuilder.ReferenceExisting(app::DefaultServerCluster::GlobalAttributes()), CHIP_NO_ERROR);
@@ -91,21 +91,12 @@ TEST_F(TestBasicInformationCluster, TestAttributes)
9191

9292
ReadOnlyBufferBuilder<AttributeEntry> expectedBuilder;
9393
ASSERT_EQ(expectedBuilder.AppendElements({
94-
DataModelRevision::kMetadataEntry,
95-
VendorName::kMetadataEntry,
96-
VendorID::kMetadataEntry,
97-
ProductName::kMetadataEntry,
98-
ProductID::kMetadataEntry,
99-
NodeLabel::kMetadataEntry,
100-
Location::kMetadataEntry,
101-
HardwareVersion::kMetadataEntry,
102-
HardwareVersionString::kMetadataEntry,
103-
SoftwareVersion::kMetadataEntry,
104-
SoftwareVersionString::kMetadataEntry,
105-
CapabilityMinima::kMetadataEntry,
106-
SpecificationVersion::kMetadataEntry,
94+
DataModelRevision::kMetadataEntry, VendorName::kMetadataEntry, VendorID::kMetadataEntry,
95+
ProductName::kMetadataEntry, ProductID::kMetadataEntry, NodeLabel::kMetadataEntry, Location::kMetadataEntry,
96+
HardwareVersion::kMetadataEntry, HardwareVersionString::kMetadataEntry, SoftwareVersion::kMetadataEntry,
97+
SoftwareVersionString::kMetadataEntry, CapabilityMinima::kMetadataEntry, SpecificationVersion::kMetadataEntry,
10798
MaxPathsPerInvoke::kMetadataEntry,
108-
ConfigurationVersion::kMetadataEntry,
99+
// ConfigurationVersion::kMetadataEntry,
109100
}),
110101
CHIP_NO_ERROR);
111102
ASSERT_EQ(expectedBuilder.ReferenceExisting(app::DefaultServerCluster::GlobalAttributes()), CHIP_NO_ERROR);
@@ -146,7 +137,7 @@ TEST_F(TestBasicInformationCluster, TestAttributes)
146137
CapabilityMinima::kMetadataEntry,
147138
SpecificationVersion::kMetadataEntry,
148139
MaxPathsPerInvoke::kMetadataEntry,
149-
ConfigurationVersion::kMetadataEntry,
140+
// ConfigurationVersion::kMetadataEntry,
150141
UniqueID::kMetadataEntry,
151142
ManufacturingDate::kMetadataEntry,
152143
PartNumber::kMetadataEntry,

0 commit comments

Comments
 (0)