[pypy-commit] pypy default: fix test_tabs to check rpython too and make the test pass

bivab noreply at buildbot.pypy.org
Fri Apr 5 19:43:21 CEST 2013


Author: David Schneider <david.schneider at picle.org>
Branch: 
Changeset: r63067:8a5f5f3f1a51
Date: 2013-04-05 19:36 +0200
http://bitbucket.org/pypy/pypy/changeset/8a5f5f3f1a51/

Log:	fix test_tabs to check rpython too and make the test pass

diff --git a/pypy/tool/test/test_tab.py b/pypy/tool/test/test_tab.py
--- a/pypy/tool/test/test_tab.py
+++ b/pypy/tool/test/test_tab.py
@@ -5,7 +5,7 @@
 import os
 from pypy.conftest import pypydir
 
-ROOT = pypydir
+ROOT = os.path.abspath(os.path.join(pypydir, '..'))
 EXCLUDE = {}
 
 
diff --git a/rpython/jit/backend/arm/assembler.py b/rpython/jit/backend/arm/assembler.py
--- a/rpython/jit/backend/arm/assembler.py
+++ b/rpython/jit/backend/arm/assembler.py
@@ -305,7 +305,7 @@
             self._restore_exception(mc, exc0, exc1)
             mc.VPOP([vfpr.value for vfpr in r.caller_vfp_resp])
             assert exc0 is not None
-	    assert exc1 is not None
+            assert exc1 is not None
             mc.POP([gpr.value for gpr in r.caller_resp] +
                             [exc0.value, exc1.value])
         #
@@ -1060,8 +1060,7 @@
             self.mc.PUSH([helper.value], cond=cond)
         self.load_reg(self.mc, loc, r.fp, offset, cond=cond, helper=helper)
         if save_helper:
-	    self.mc.POP([helper.value], cond=cond)
-
+            self.mc.POP([helper.value], cond=cond)
 
     def _mov_imm_float_to_loc(self, prev_loc, loc, cond=c.AL):
         if loc.is_vfp_reg():
diff --git a/rpython/jit/backend/arm/test/test_calling_convention.py b/rpython/jit/backend/arm/test/test_calling_convention.py
--- a/rpython/jit/backend/arm/test/test_calling_convention.py
+++ b/rpython/jit/backend/arm/test/test_calling_convention.py
@@ -72,7 +72,7 @@
         callargs = []
         def func(f0, f1, f2, f3, f4, f5, f6, i0, f7, i1, f8, f9):
             callargs.append(zip(range(12),
-			[f0, f1, f2, f3, f4, f5, f6, i0, f7, i1, f8, f9]))
+                        [f0, f1, f2, f3, f4, f5, f6, i0, f7, i1, f8, f9]))
             return f0 + f1 + f2 + f3 + f4 + f5 + f6 + float(i0 + i1) + f7 + f8 + f9
         F = lltype.Float
         I = lltype.Signed
@@ -103,7 +103,7 @@
         callargs = []
         def func(f0, f1, f2, f3, f4, f5, f6, f7, f8, f9):
             callargs.append(zip(range(10),
-			[f0, f1, f2, f3, f4, f5, f6, f7, f8, f9]))
+                        [f0, f1, f2, f3, f4, f5, f6, f7, f8, f9]))
             return f0 + f1 + f2 + f3 + f4 + f5 + f6 + f7 + f8 + f9
         F = lltype.Float
         FUNC = self.FuncType([F] * 10, F)
@@ -125,7 +125,7 @@
         callargs = []
         def func(f0, f1, f2, f3, f4, f5, f6, f7, f8, f9):
             callargs.append(zip(range(10),
-			[f0, f1, f2, f3, f4, f5, f6, f7, f8, f9]))
+                        [f0, f1, f2, f3, f4, f5, f6, f7, f8, f9]))
             return f0 + f1 + f2 + f3 + f4 + f5 + f6 + f7 + f8 + f9
 
         I = lltype.Signed
diff --git a/rpython/jit/backend/test/calling_convention_test.py b/rpython/jit/backend/test/calling_convention_test.py
--- a/rpython/jit/backend/test/calling_convention_test.py
+++ b/rpython/jit/backend/test/calling_convention_test.py
@@ -384,7 +384,7 @@
 
     def test_call_aligned_explicit_check(self):
         if (not platform.machine().startswith('arm') and
-		sys.maxint == 2 ** 31 - 1): # XXX is still necessary on x86?
+                sys.maxint == 2 ** 31 - 1): # XXX is still necessary on x86?
             py.test.skip("libffi on 32bit is broken")
         cpu = self.cpu
         if not cpu.supports_floats:
diff --git a/rpython/jit/backend/x86/runner.py b/rpython/jit/backend/x86/runner.py
--- a/rpython/jit/backend/x86/runner.py
+++ b/rpython/jit/backend/x86/runner.py
@@ -58,10 +58,10 @@
         self.assembler = Assembler386(self, self.translate_support_code)
 
     def build_regalloc(self):
-	''' for tests'''
-	from rpython.jit.backend.x86.regalloc import RegAlloc
-	assert self.assembler is not None
-	return RegAlloc(self.assembler, False)
+        ''' for tests'''
+        from rpython.jit.backend.x86.regalloc import RegAlloc
+        assert self.assembler is not None
+        return RegAlloc(self.assembler, False)
 
     def setup_once(self):
         self.profile_agent.startup()
diff --git a/rpython/jit/metainterp/optimizeopt/test/test_optimizeopt.py b/rpython/jit/metainterp/optimizeopt/test/test_optimizeopt.py
--- a/rpython/jit/metainterp/optimizeopt/test/test_optimizeopt.py
+++ b/rpython/jit/metainterp/optimizeopt/test/test_optimizeopt.py
@@ -4282,9 +4282,9 @@
         self.optimize_loop(ops, expected)
 
     def test_add_sub_ovf_second_operation_regular(self):
-	py.test.skip("Smalltalk would like this to pass")
-	# This situation occurs in Smalltalk because it uses 1-based indexing.
-	# The below code is equivalent to a loop over an array.
+        py.test.skip("Smalltalk would like this to pass")
+        # This situation occurs in Smalltalk because it uses 1-based indexing.
+        # The below code is equivalent to a loop over an array.
         ops = """
         [i1]
         i2 = int_sub(i1, 1)


More information about the pypy-commit mailing list