From: <pj...@us...> - 2009-05-27 02:43:23
|
Revision: 6391 http://jython.svn.sourceforge.net/jython/?rev=6391&view=rev Author: pjenvey Date: 2009-05-27 02:43:21 +0000 (Wed, 27 May 2009) Log Message: ----------- windows test fixes: o help test_ftruncate w/ an extra fsync o handle ':' in the test_sax.test_expat_locator_withinfo url o recompile test_java_subclasses' class files and write them in binary mode in hopes this satisifies the buildbot env o regrtest typo Modified Paths: -------------- trunk/jython/Lib/test/regrtest.py trunk/jython/Lib/test/test_fileno.py trunk/jython/Lib/test/test_java_subclasses.py trunk/jython/Lib/test/test_sax.py Modified: trunk/jython/Lib/test/regrtest.py =================================================================== --- trunk/jython/Lib/test/regrtest.py 2009-05-27 02:42:18 UTC (rev 6390) +++ trunk/jython/Lib/test/regrtest.py 2009-05-27 02:43:21 UTC (rev 6391) @@ -1533,7 +1533,7 @@ if test_support.is_jython: if os._name != 'posix': self.expected.update([ - 'test_grb', 'test_mhlib', 'test_posix', 'test_pwd', + 'test_grp', 'test_mhlib', 'test_posix', 'test_pwd', 'test_signal']) self.valid = True Modified: trunk/jython/Lib/test/test_fileno.py =================================================================== --- trunk/jython/Lib/test/test_fileno.py 2009-05-27 02:42:18 UTC (rev 6390) +++ trunk/jython/Lib/test/test_fileno.py 2009-05-27 02:43:21 UTC (rev 6391) @@ -24,6 +24,7 @@ def test_ftruncate(self): self.fp.write('jython filenos') self.fp.flush() + os.fsync(self.fd) self.assertEqual(os.path.getsize(self.filename), 14) os.ftruncate(self.fd, 8) self.assertEqual(os.path.getsize(self.filename), 8) Modified: trunk/jython/Lib/test/test_java_subclasses.py =================================================================== --- trunk/jython/Lib/test/test_java_subclasses.py 2009-05-27 02:42:18 UTC (rev 6390) +++ trunk/jython/Lib/test/test_java_subclasses.py 2009-05-27 02:43:21 UTC (rev 6391) @@ -248,7 +248,7 @@ Checks for http://jython.org/bugs/1861985 ''' def setUp(self): - out = open('Abstract.class', 'w') + out = open('Abstract.class', 'wb') out.write(ABSTRACT_CLASS) out.close() self.orig_syspath = sys.path[:] @@ -277,13 +277,12 @@ """ # The following is the correspoding bytecode for ContextAbstract compiled with javac 1.5 # Needs to be named differently than Abstract above so the class loader won't just use it -CONTEXT_ABSTRACT = '''\ -eJxdjr1uwjAUhc8lbgIh/AVegA0YQJ1BlRBSp6gdWrE7wQKjEEvBVH0tFip14AF4KMQ17YSHc3yu -vuPry/X3DOAZ3RACrRAe2gE6AWKCP9OFti8EbzBcEsTCrBShlehCvR12qSo/ZZrzJE5MJvOlLLXL -/0NhN3pP6CQLU1j1befp3pYys1N+d6fsxqwI4Yc5lJl61a7QewDHW/klIzzBjxDB58UPAKHtkEku -i/XkPd2qzIo+/1/AnQrIdVkDTlN2Yq+NfkCjEyrHO1JlbXLF3QV7lbXGKfqDEaIOCHL7ORMad7J5 -A7yvPDQ= -'''.decode('base64').decode('zlib') +CONTEXT_ABSTRACT = """\ +eJxdTsEOwVAQnK2n1aq2Bz/ghgNxF4lInIQDcX9tX6jQJvWI33IhcfABPkrs69EedjKzM7v7+b7e +AEaIPAj4HmpoOQgchAR7nOWZnhBq3d6WIGZFqgjhIsvV8nKKVbmR8ZEV+6T0vkgJ3rq4lImaZ0Zt +z4pcq5uexmddykQPDvIqfdRh+3Bh86I/AyEyluFR5rvhKj6oRIsO/yNgygKZLHeHWY+RGN3+E9R/ +wLozITS4BxwxdsHYgBBkrlVTr9KbP6qaLFc= +""".decode('base64').decode('zlib') class ContextClassloaderTest(unittest.TestCase): '''Classes on the context classloader should be importable and subclassable. Modified: trunk/jython/Lib/test/test_sax.py =================================================================== --- trunk/jython/Lib/test/test_sax.py 2009-05-27 02:42:18 UTC (rev 6390) +++ trunk/jython/Lib/test/test_sax.py 2009-05-27 02:43:21 UTC (rev 6391) @@ -479,9 +479,8 @@ # replace the backslashes with forward testfile = testfile.replace('\\', '/') - # XXX: may not match getSystemId when the filename contains funky - # characters (like ':') - expected = urllib.quote(testfile) + # urllib.quote isn't the exact encoder (e.g. ':' isn't escaped) + expected = urllib.quote(testfile).replace('%3A', ':') return xmlgen.location.getSystemId().endswith(expected) and \ xmlgen.location.getPublicId() is None This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |