summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2019-09-28 14:13:44 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2019-10-05 20:02:51 +0300
commitf1ab117e81e55b9b030dd921394dde294f7c3dc0 (patch)
tree4e7bfc405cd1d02deb10e91cd3457c7acba63d1c /test
parent5a952df386e2587e72dc378a1c97281e70ad57f5 (diff)
libcamera: controls: Remove ControlInfo::id
The ControlInfo id member is only used in the toString() method of the class, and nowhere else externally. The same way that ControlValue doesn't store a ControlId, ControlInfo shouldn't. Remove it. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Diffstat (limited to 'test')
-rw-r--r--test/controls/control_info.cpp18
1 files changed, 2 insertions, 16 deletions
diff --git a/test/controls/control_info.cpp b/test/controls/control_info.cpp
index dbc43df8..9cf59185 100644
--- a/test/controls/control_info.cpp
+++ b/test/controls/control_info.cpp
@@ -24,14 +24,7 @@ protected:
* Test information retrieval from a control with no minimum
* and maximum.
*/
- ControlInfo brightness(controls::Brightness);
-
- if (brightness.id() != controls::Brightness ||
- brightness.id().type() != ControlTypeInteger32 ||
- brightness.id().name() != std::string("Brightness")) {
- cout << "Invalid control identification for Brightness" << endl;
- return TestFail;
- }
+ ControlInfo brightness;
if (brightness.min().get<int32_t>() != 0 ||
brightness.max().get<int32_t>() != 0) {
@@ -43,14 +36,7 @@ protected:
* Test information retrieval from a control with a minimum and
* a maximum value.
*/
- ControlInfo contrast(controls::Contrast, 10, 200);
-
- if (contrast.id() != controls::Contrast ||
- contrast.id().type() != ControlTypeInteger32 ||
- contrast.id().name() != std::string("Contrast")) {
- cout << "Invalid control identification for Contrast" << endl;
- return TestFail;
- }
+ ControlInfo contrast(10, 200);
if (contrast.min().get<int32_t>() != 10 ||
contrast.max().get<int32_t>() != 200) {