##// END OF EJS Templates
run-tests: resurrect the wifexited polyfill (backout 6ab5a1c9ea3c)...
Matt Harbison -
r25177:c3459555 default
parent child Browse files
Show More
@@ -103,6 +103,9 b' else:'
103
103
104 _strpath = _bytespath
104 _strpath = _bytespath
105
105
106 # For Windows support
107 wifexited = getattr(os, "WIFEXITED", lambda x: False)
108
106 def checkportisavailable(port):
109 def checkportisavailable(port):
107 """return true if a port seems free to bind on localhost"""
110 """return true if a port seems free to bind on localhost"""
108 try:
111 try:
@@ -804,7 +807,7 b' class Test(unittest.TestCase):'
804 raise
807 raise
805
808
806 ret = proc.wait()
809 ret = proc.wait()
807 if os.WIFEXITED(ret):
810 if wifexited(ret):
808 ret = os.WEXITSTATUS(ret)
811 ret = os.WEXITSTATUS(ret)
809
812
810 if proc.timeout:
813 if proc.timeout:
@@ -905,7 +908,7 b' class TTest(Test):'
905 self._testtmp, 0, self._getenv())
908 self._testtmp, 0, self._getenv())
906 stdout, stderr = proc.communicate()
909 stdout, stderr = proc.communicate()
907 ret = proc.wait()
910 ret = proc.wait()
908 if os.WIFEXITED(ret):
911 if wifexited(ret):
909 ret = os.WEXITSTATUS(ret)
912 ret = os.WEXITSTATUS(ret)
910 if ret == 2:
913 if ret == 2:
911 print(stdout)
914 print(stdout)
General Comments 0
You need to be logged in to leave comments. Login now