Commit 5357af89 authored by Neal Norwitz's avatar Neal Norwitz

Add a tiny sleep and additional flush to force the file to really be synced.

parent bfb7d2dd
import unittest import unittest
from test import test_support from test import test_support
import os
import os, resource import resource
import time
# This test is checking a few specific problem spots with the resource module. # This test is checking a few specific problem spots with the resource module.
...@@ -59,6 +60,8 @@ class ResourceTest(unittest.TestCase): ...@@ -59,6 +60,8 @@ class ResourceTest(unittest.TestCase):
# an attempt to ensure the file is really synced and # an attempt to ensure the file is really synced and
# the exception raised. # the exception raised.
for i in range(5): for i in range(5):
time.sleep(.1)
f.flush()
f.close() f.close()
except IOError: except IOError:
if not limit_set: if not limit_set:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment