Instead of calling a executable with the images as parameters, implement a cpp file to run the unittests.