test: ipa: ipa_interface: Pass configuration file to IPA init()

Pass the vimc IPA dummy configuration file to the IPA init() function.
This will be used by the IPA to validate the init() call.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
Laurent Pinchart 2020-04-27 05:05:23 +03:00
parent e951a2af20
commit 32df46f0b6

View file

@ -98,8 +98,13 @@ protected:
} }
/* Test initialization of IPA module. */ /* Test initialization of IPA module. */
IPASettings settings; std::string conf = ipa_->configurationFile("vimc.conf");
ipa_->init(settings); int ret = ipa_->init(IPASettings{ conf });
if (ret < 0) {
cerr << "IPA interface init() failed" << endl;
return TestFail;
}
timer.start(1000); timer.start(1000);
while (timer.isRunning() && trace_ != IPAOperationInit) while (timer.isRunning() && trace_ != IPAOperationInit)
dispatcher->processEvents(); dispatcher->processEvents();
@ -155,7 +160,7 @@ private:
} }
std::shared_ptr<PipelineHandler> pipe_; std::shared_ptr<PipelineHandler> pipe_;
std::unique_ptr<IPAInterface> ipa_; std::unique_ptr<IPAProxy> ipa_;
enum IPAOperationCode trace_; enum IPAOperationCode trace_;
EventNotifier *notifier_; EventNotifier *notifier_;
int fd_; int fd_;