Fix warning:  QProcess: Destroyed while process is still running.

The fix is to wait for the process to finish before continuing (this takes a few milliseconds)
test: ensure cli.py processed is killed at the end of the test