[pypy-svn] r61044 - in pypy/trunk/lib-python: . modified-2.5.2/test

antocuni at codespeak.net antocuni at codespeak.net
Fri Jan 16 17:52:22 CET 2009


Author: antocuni
Date: Fri Jan 16 17:52:22 2009
New Revision: 61044

Modified:
   pypy/trunk/lib-python/failure_list.txt
   pypy/trunk/lib-python/modified-2.5.2/test/test_optparse.py
Log:
fix test_optparse, update failure_list



Modified: pypy/trunk/lib-python/failure_list.txt
==============================================================================
--- pypy/trunk/lib-python/failure_list.txt	(original)
+++ pypy/trunk/lib-python/failure_list.txt	Fri Jan 16 17:52:22 2009
@@ -26,7 +26,7 @@
 test_gettext                 !   check this use of unicode()
 test_grammar                     implementation detail
 test_import                      importing from pyc-files-without-py-file disabled by default
-test_importhooks             !   unknown
+test_importhooks             !   unknown  # SHOULD BE FIXED NOW, check nightly tests
 test_inspect                 !   test_wrapped_decorator: try to fix;  isbuiltin([].append): cry and maaaybe try to fix
 test_iterlen                     somehow implementation detail (missing __length_hint__())
 test_itertools                   same as test_iterlen
@@ -35,7 +35,7 @@
 test_mutants                     the test is probably too precise in the failure it expects
 test_new                         new.instancemethod(x, None) should fail, but no hurry
 test_normalization               test skipped
-test_optparse                !   test needs some fixes, but still, some failures are strange
+test_optparse                !   test needs some fixes, but still, some failures are strange # SHOULD BE FIXED N?OW
 test_parser                      missing parser.compilest().  I don't think we care for now
 test_peepholer                   implementation detail (might be useful to look, though)
 test_pep277                      NT only

Modified: pypy/trunk/lib-python/modified-2.5.2/test/test_optparse.py
==============================================================================
--- pypy/trunk/lib-python/modified-2.5.2/test/test_optparse.py	(original)
+++ pypy/trunk/lib-python/modified-2.5.2/test/test_optparse.py	Fri Jan 16 17:52:22 2009
@@ -238,7 +238,7 @@
 
     def test_attr_invalid(self):
         d = {'foo': None, 'bar': None}
-        msg = ', '.join(d.keys())
+        msg = ', '.join(sorted(d.keys())) # avoid order-dependant issues
         self.assertOptionError(
             "option -b: invalid keyword arguments: %s" % msg,
             ["-b"], d)
@@ -1596,10 +1596,11 @@
         self.parser.add_option("-l", type=long)
 
     def test_parse_num_fail(self):
+        # "empty string for int()" is pypy's error message
         self.assertRaises(
             _parse_num, ("", int), {},
             ValueError,
-            re.compile(r"invalid literal for int().*: '?'?"))
+            re.compile(r"(invalid literal for int().*: '?'?|empty string for int())"))
         self.assertRaises(
             _parse_num, ("0xOoops", long), {},
             ValueError,



More information about the Pypy-commit mailing list