[Python-checkins] python/dist/src/Lib/test regrtest.py,1.131,1.132 test_timeout.py,1.11,1.12
nnorwitz@users.sourceforge.net
nnorwitz@users.sourceforge.net
Fri, 28 Feb 2003 11:53:43 -0800
Update of /cvsroot/python/python/dist/src/Lib/test
In directory sc8-pr-cvs1:/tmp/cvs-serv18489/Lib/test
Modified Files:
regrtest.py test_timeout.py
Log Message:
Fix SF bugs #692951 and 692988, test_timeout.py needs 'network' resource
require -u network to run test_timeout since
it fails when not connected to a network.
Index: regrtest.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/test/regrtest.py,v
retrieving revision 1.131
retrieving revision 1.132
diff -C2 -d -r1.131 -r1.132
*** regrtest.py 26 Feb 2003 19:51:23 -0000 1.131
--- regrtest.py 28 Feb 2003 19:53:32 -0000 1.132
***************
*** 544,547 ****
--- 544,550 ----
# Controlled by test_socket_ssl.skip_expected. Requires the network
# resource, and a socket module with ssl support.
+ # test_timeout
+ # Controlled by test_timeout.skip_expected. Requires the network
+ # resource and a socket module.
_expectations = {
***************
*** 946,949 ****
--- 949,953 ----
from test import test_normalization
from test import test_socket_ssl
+ from test import test_timeout
self.valid = False
***************
*** 960,963 ****
--- 964,970 ----
if test_socket_ssl.skip_expected:
self.expected.add('test_socket_ssl')
+
+ if test_timeout.skip_expected:
+ self.expected.add('test_timeout')
if not sys.platform in ("mac", "darwin"):
Index: test_timeout.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/test/test_timeout.py,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** test_timeout.py 21 Feb 2003 16:45:41 -0000 1.11
--- test_timeout.py 28 Feb 2003 19:53:34 -0000 1.12
***************
*** 4,7 ****
--- 4,10 ----
from test import test_support
+ # This requires the 'network' resource as given on the regrtest command line.
+ skip_expected = not test_support.is_resource_enabled('network')
+
import time
import socket
***************
*** 183,186 ****
--- 186,191 ----
def test_main():
+ test_support.requires('network')
+
suite = unittest.TestSuite()
suite.addTest(unittest.makeSuite(CreationTestCase))