run-tests: drop wifexited polyfill
authorAugie Fackler <augie@google.com>
Sun, 17 May 2015 21:15:04 -0400
changeset 25155 6ab5a1c9ea3c
parent 25154 7b3feaa1ee3f
child 25156 c87257002598
run-tests: drop wifexited polyfill os.WIFEXITED exists as of python 2.6 for me, so we no longer need this polyfill.
tests/run-tests.py
--- a/tests/run-tests.py	Mon May 18 11:43:10 2015 -0400
+++ b/tests/run-tests.py	Sun May 17 21:15:04 2015 -0400
@@ -87,8 +87,6 @@
 if sys.version_info < (2, 5):
     subprocess._cleanup = lambda: None
 
-wifexited = getattr(os, "WIFEXITED", lambda x: False)
-
 def checkportisavailable(port):
     """return true if a port seems free to bind on localhost"""
     try:
@@ -789,7 +787,7 @@
             raise
 
         ret = proc.wait()
-        if wifexited(ret):
+        if os.WIFEXITED(ret):
             ret = os.WEXITSTATUS(ret)
 
         if proc.timeout:
@@ -890,7 +888,7 @@
                       self._testtmp, 0, self._getenv())
         stdout, stderr = proc.communicate()
         ret = proc.wait()
-        if wifexited(ret):
+        if os.WIFEXITED(ret):
             ret = os.WEXITSTATUS(ret)
         if ret == 2:
             print(stdout)