Commits

Christian Tismer committed f3ad459 Merge

hg merge default

Comments (0)

Files changed (2)

pypy/objspace/std/test/test_userobject.py

             skip("disabled")
         if self.runappdirect:
             total = 500000
+            def rand():
+                import random
+                return random.randrange(0, 5)
         else:
             total = 50
+            rand = self.rand
         #
         class A(object):
             hash = None
             a = A()
             a.next = tail.next
             tail.next = a
-            for j in range(self.rand()):
+            for j in range(rand()):
                 any = any.next
             if any.hash is None:
                 any.hash = hash(any)

pypy/translator/test/test_unsimplify.py

             return x * 6
         def hello_world():
             if we_are_translated():
-                fd = os.open(tmpfile, os.O_WRONLY | os.O_CREAT, 0)
+                fd = os.open(tmpfile, os.O_WRONLY | os.O_CREAT, 0644)
                 os.close(fd)
         graph, t = translate(f, [int], type_system)
         call_initial_function(t, hello_world)
             return x * 6
         def goodbye_world():
             if we_are_translated():
-                fd = os.open(tmpfile, os.O_WRONLY | os.O_CREAT, 0)
+                fd = os.open(tmpfile, os.O_WRONLY | os.O_CREAT, 0644)
                 os.close(fd)
         graph, t = translate(f, [int], type_system)
         call_final_function(t, goodbye_world)