def OFF_test_run_out_of_pty (self):
'''This assumes that the tested platform has < 10000 pty devices.
This test currently does not work under Solaris.
Under Solaris it runs out of file descriptors first and
ld.so starts to barf:
ld.so.1: pt_chmod: fatal: /usr/lib/libc.so.1: Too many open files
'''
plist=[]
for count in range (0,10000):
try:
plist.append (pexpect.spawn('ls -l'))
except pexpect.ExceptionPexpect:
for c in range (0, count):
plist[c].close()
return
except Exception:
err = sys.exc_info()[1]
self.fail ('Expected ExceptionPexpect. ' + str(err))
self.fail ('Could not run out of pty devices. This may be OK.')
test_run_out_of_pty.py 文件源码
python
阅读 21
收藏 0
点赞 0
评论 0
评论列表
文章目录