I want to write a testing program. It will open a special *.tests file and test direct program with tests from the file.
I need to:
- Run some program. e.g
./main -testing 45 563 67 - Listen to result.
How I can to do it? I want to run program main with some tests and listen to its result.
You should ues the
QProcessclass to start your program.Then you can use the
waitForFinishedto wait for it to finish.exitCodewill give you the return code.The
readAllStandardOutput(or*Error) methods allow you to read what the process has output to the console.