diff options
author | Michael Felt <aixtools@users.noreply.github.com> | 2018-12-26 04:54:22 +0100 |
---|---|---|
committer | Nick Coghlan <ncoghlan@gmail.com> | 2018-12-26 13:54:22 +1000 |
commit | 22462da70c1ae015a60a7b821547bc6d2b5bc265 (patch) | |
tree | 5f36abcea8207375e4de8659197473884bcfbb3b /Lib | |
parent | 5661459f5f508ea4bd24c13cbc861543f283147e (diff) | |
download | cpython-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.py | 4 |
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() |