[pypy-commit] pypy default: skip this test with -A

antocuni noreply at buildbot.pypy.org
Tue May 22 12:20:32 CEST 2012


Author: Antonio Cuni <anto.cuni at gmail.com>
Branch: 
Changeset: r55151:b9ee8941f2cb
Date: 2012-05-22 12:20 +0200
http://bitbucket.org/pypy/pypy/changeset/b9ee8941f2cb/

Log:	skip this test with -A

diff --git a/pypy/module/_ffi/test/test_struct.py b/pypy/module/_ffi/test/test_struct.py
--- a/pypy/module/_ffi/test/test_struct.py
+++ b/pypy/module/_ffi/test/test_struct.py
@@ -1,5 +1,5 @@
 import sys
-from pypy.conftest import gettestobjspace
+from pypy.conftest import gettestobjspace, option
 from pypy.module._ffi.test.test_funcptr import BaseAppTestFFI
 from pypy.module._ffi.interp_struct import compute_size_and_alignement, W_Field
 from pypy.module._ffi.interp_ffitype import app_types, W_FFIType
@@ -62,6 +62,7 @@
         dummy_type.c_alignment = rffi.cast(rffi.USHORT, 0)
         dummy_type.c_type = rffi.cast(rffi.USHORT, 0)
         cls.w_dummy_type = W_FFIType('dummy', dummy_type)
+        cls.w_runappdirect = cls.space.wrap(option.runappdirect)
         
     def test__StructDescr(self):
         from _ffi import _StructDescr, Field, types
@@ -99,6 +100,8 @@
         raises(AttributeError, "struct.setfield('missing', 42)")
 
     def test_unknown_type(self):
+        if self.runappdirect:
+            skip('cannot use self.dummy_type with -A')
         from _ffi import _StructDescr, Field
         fields = [
             Field('x', self.dummy_type),


More information about the pypy-commit mailing list