summaryrefslogtreecommitdiffstats
path: root/Lib/test
diff options
context:
space:
mode:
authorNadeem Vawda <nadeem.vawda@gmail.com>2011-04-18 23:41:28 (GMT)
committerNadeem Vawda <nadeem.vawda@gmail.com>2011-04-18 23:41:28 (GMT)
commitd7d01cd80cd8b855119b8a312987aee37aff1ef9 (patch)
tree5def0a4bd0501f8e8e108d5b2ed7c79b2567255a /Lib/test
parent6a45d3b6ae46291a2ee6d07fe67f5603cf8a1515 (diff)
parentcc3f02938037550118e008e9130534b84e887682 (diff)
downloadcpython-d7d01cd80cd8b855119b8a312987aee37aff1ef9.zip
cpython-d7d01cd80cd8b855119b8a312987aee37aff1ef9.tar.gz
cpython-d7d01cd80cd8b855119b8a312987aee37aff1ef9.tar.bz2
Merge test_startfile fix from 3.2.
Diffstat (limited to 'Lib/test')
-rw-r--r--Lib/test/test_startfile.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/test/test_startfile.py b/Lib/test/test_startfile.py
index 7a003eb..dd505bf 100644
--- a/Lib/test/test_startfile.py
+++ b/Lib/test/test_startfile.py
@@ -11,6 +11,7 @@ import unittest
from test import support
import os
from os import path
+from time import sleep
startfile = support.get_attribute(os, 'startfile')
@@ -23,6 +24,10 @@ class TestCase(unittest.TestCase):
empty = path.join(path.dirname(__file__), "empty.vbs")
startfile(empty)
startfile(empty, "open")
+ # Give the child process some time to exit before we finish.
+ # Otherwise the cleanup code will not be able to delete the cwd,
+ # because it is still in use.
+ sleep(0.1)
def test_main():
support.run_unittest(TestCase)