Include the timeout value in TimeoutExpired.
This was the original intention, but it wasn't threaded all the way through due
to 'endtime'. Also added a trivial assertion to get coverage of __str__.
diff --git a/Lib/test/test_subprocess.py b/Lib/test/test_subprocess.py
index 3156543..00cf0d5 100644
--- a/Lib/test/test_subprocess.py
+++ b/Lib/test/test_subprocess.py
@@ -651,7 +651,9 @@
def test_wait_timeout(self):
p = subprocess.Popen([sys.executable,
"-c", "import time; time.sleep(0.1)"])
- self.assertRaises(subprocess.TimeoutExpired, p.wait, timeout=0.01)
+ with self.assertRaises(subprocess.TimeoutExpired) as c:
+ p.wait(timeout=0.01)
+ self.assertIn("0.01", str(c.exception)) # For coverage of __str__.
self.assertEqual(p.wait(timeout=2), 0)