test: media_device: Add test for acquire() and release()
The interfaces MediaDevice::{open,close}() are about to be made private, replace them with a test of MediaDevice::{acquire,release}() instead. The new test will implicitly tests the open() and close() methods as they are about to be move inside acquire() and release() which will remain public. Signed-off-by: Niklas Söderlund <niklas.soderlund@ragnatech.se> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
This commit is contained in:
parent
9654d1f64a
commit
9c1fe51ebc
3 changed files with 34 additions and 11 deletions
|
@ -113,17 +113,6 @@ int MediaDevicePrintTest::testMediaDevice(const string deviceNode)
|
|||
MediaDevice dev(deviceNode);
|
||||
int ret;
|
||||
|
||||
/* Fuzzy open/close sequence. */
|
||||
ret = dev.open();
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = dev.open();
|
||||
if (!ret)
|
||||
return ret;
|
||||
|
||||
dev.close();
|
||||
|
||||
ret = dev.populate();
|
||||
if (ret)
|
||||
return ret;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue