During developing automatic tests for our application using QFTest I encountered an interesting problem.
The test I’m working on now hast to execute shell commands both on windows and linux operating systems. The problem is to get the executed commands output. On linux I found the „getoutput” function from „commands” package and it could resolve my problem easily. Unfortunatelly on windows systems this function is not available. Now I’m handling this problem by executing the shell command with „>” operator and printing the output to a file and reading the content of it into a variable. Besides I have permission problems on various operating systems needless to say it is not the best solution.
My questions are:
-How could I be able to get the executed shell commands output without using file printing and file reading or
-How else could I implement this problem on windows systems?