diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2022-10-03 19:47:17 +0300 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2022-10-04 17:58:00 +0300 |
commit | 2cc5654633c3a1c61f6899226c533308af858703 (patch) | |
tree | c601a9f9cd8d9f52d8a5ff0cb744bdc9db11c396 /test | |
parent | dbd937e37500ea62e2967fd6669158aee92841c3 (diff) |
test: v4l2_m2mdevice: Test control enumeration
Verify that the V4L2M2MDevice correctly enumerates controls supported by
the device. The test currently fails, and will be fixed by a subsequent
patch.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Umang Jain <umang.jain@ideasonboard.com>
Reviewed-by: Xavier Roumegue <xavier.roumegue@oss.nxp.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/v4l2_videodevice/v4l2_m2mdevice.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/v4l2_videodevice/v4l2_m2mdevice.cpp b/test/v4l2_videodevice/v4l2_m2mdevice.cpp index 852b853f..c45f581a 100644 --- a/test/v4l2_videodevice/v4l2_m2mdevice.cpp +++ b/test/v4l2_videodevice/v4l2_m2mdevice.cpp @@ -95,6 +95,11 @@ protected: V4L2VideoDevice *capture = vim2m_->capture(); V4L2VideoDevice *output = vim2m_->output(); + if (capture->controls().empty() || output->controls().empty()) { + cerr << "VIM2M device has no control" << endl; + return TestFail; + } + V4L2DeviceFormat format = {}; if (capture->getFormat(&format)) { cerr << "Failed to get capture format" << endl; |