Cannot run pytest tests with ctest

In haf local development the way to run tests is with ctest. All tests can be lauched this way. The only exception is python tests.