[pypy-svn] r20454 - pypy/branch/somepbc-refactoring/pypy/translator/test

arigo at codespeak.net arigo at codespeak.net
Wed Nov 30 21:08:36 CET 2005


Author: arigo
Date: Wed Nov 30 21:08:35 2005
New Revision: 20454

Modified:
   pypy/branch/somepbc-refactoring/pypy/translator/test/test_annrpython.py
Log:
A more mean test.


Modified: pypy/branch/somepbc-refactoring/pypy/translator/test/test_annrpython.py
==============================================================================
--- pypy/branch/somepbc-refactoring/pypy/translator/test/test_annrpython.py	(original)
+++ pypy/branch/somepbc-refactoring/pypy/translator/test/test_annrpython.py	Wed Nov 30 21:08:35 2005
@@ -1860,15 +1860,16 @@
             def _freeze_(self):
                 return True
         X1 = X(1)
-        Y2 = Y(2)
+        Y2 = Y("hello")
         fromcache = SpaceCache().getorbuild
         def f():
-            return fromcache(CacheX).getorbuild(X1) + \
-                   fromcache(CacheY).getorbuild(Y2)
+            return (fromcache(CacheX).getorbuild(X1),
+                    fromcache(CacheY).getorbuild(Y2))
 
         a = self.RPythonAnnotator()
         s = a.build_types(f, [])
-        assert s.knowntype == int
+        assert s.items[0].knowntype == int
+        assert s.items[1].knowntype == str
 
 def g(n):
     return [0,1,2,n]



More information about the Pypy-commit mailing list