I have a regression test script written in python that calls a number of test scripts also written in python and executes them. Every test script returns either pass
or fail
. I want to make sure that the regression test script doesn't wait forever for a return value and stop the running test script after sometime. I came across this answer and it works perfectly well. Except for a small caveat. The p.join()
will not return a value from the test script which is essential. I can not use message passing, or a global variable since it is a huge code base used across multiple teams. Can someone please suggest something? I have looked at the multiprocessing
documentation but I can not seem to find a clear cut answer.
The code runs on Windows machine and python version is 2.7x.