summaryrefslogtreecommitdiffstats
path: root/Lib/ctypes
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2017-03-19 18:53:42 (GMT)
committerGitHub <noreply@github.com>2017-03-19 18:53:42 (GMT)
commitda88596a19d2cad0e85a2b3c3290b5b1d97a793d (patch)
treed32b221507445f0c652b69f1dff7a0fa00e4e06a /Lib/ctypes
parentfca705d533970011e50b3f278aab81cead39b00d (diff)
downloadcpython-da88596a19d2cad0e85a2b3c3290b5b1d97a793d.zip
cpython-da88596a19d2cad0e85a2b3c3290b5b1d97a793d.tar.gz
cpython-da88596a19d2cad0e85a2b3c3290b5b1d97a793d.tar.bz2
bpo-29845: Mark tests that use _testcapi as CPython-only (#711) (#725)
(cherry picked from commit 24c738a9e91b8f46da6166663d8ce7ec18cec784)
Diffstat (limited to 'Lib/ctypes')
-rw-r--r--Lib/ctypes/test/test_structures.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/Lib/ctypes/test/test_structures.py b/Lib/ctypes/test/test_structures.py
index 3eded77..2e778fb 100644
--- a/Lib/ctypes/test/test_structures.py
+++ b/Lib/ctypes/test/test_structures.py
@@ -2,8 +2,8 @@ import unittest
from ctypes import *
from ctypes.test import need_symbol
from struct import calcsize
-import _testcapi
import _ctypes_test
+import test.support
class SubclassesTest(unittest.TestCase):
def test_subclass(self):
@@ -202,7 +202,10 @@ class StructureTestCase(unittest.TestCase):
"_pack_": -1}
self.assertRaises(ValueError, type(Structure), "X", (Structure,), d)
+ @test.support.cpython_only
+ def test_packed_c_limits(self):
# Issue 15989
+ import _testcapi
d = {"_fields_": [("a", c_byte)],
"_pack_": _testcapi.INT_MAX + 1}
self.assertRaises(ValueError, type(Structure), "X", (Structure,), d)