summaryrefslogtreecommitdiff
path: root/Lib
diff options
context:
space:
mode:
authorMichael Felt <aixtools@users.noreply.github.com>2018-12-26 04:54:22 +0100
committerNick Coghlan <ncoghlan@gmail.com>2018-12-26 13:54:22 +1000
commit22462da70c1ae015a60a7b821547bc6d2b5bc265 (patch)
tree5f36abcea8207375e4de8659197473884bcfbb3b /Lib
parent5661459f5f508ea4bd24c13cbc861543f283147e (diff)
downloadcpython-git-22462da70c1ae015a60a7b821547bc6d2b5bc265.tar.gz
bpo-27643 - skip test_ctypes test case with XLC compiler. (GH-5164)
This test case needs "signed short" bitfields, but the IBM XLC compiler (on AIX) does not support this. Skip the code and test when AIX and XLC are used. Use __xlc__ as identifier to detect the XLC compiler.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/ctypes/test/test_bitfields.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/ctypes/test/test_bitfields.py b/Lib/ctypes/test/test_bitfields.py
index c71d71de69..992b8c4da3 100644
--- a/Lib/ctypes/test/test_bitfields.py
+++ b/Lib/ctypes/test/test_bitfields.py
@@ -40,6 +40,10 @@ class C_Test(unittest.TestCase):
self.assertEqual(getattr(b, name), func(byref(b), name.encode('ascii')))
def test_shorts(self):
+ b = BITS()
+ name = "M"
+ if func(byref(b), name.encode('ascii')) == 999:
+ self.skipTest("Compiler does not support signed short bitfields")
for i in range(256):
for name in "MNOPQRS":
b = BITS()