Skip to content

Commit ce4d267

Browse files
kulikjakmiss-islington
authored andcommitted
pythongh-91214: Skip tests failing on Solaris (pythonGH-31978)
(cherry picked from commit 34ed038) Co-authored-by: Jakub Kulík <[email protected]>
1 parent e7593c8 commit ce4d267

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

Lib/test/test_re.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2178,6 +2178,8 @@ def test_bug_20998(self):
21782178
self.assertEqual(re.fullmatch('[a-c]+', 'ABC', re.I).span(), (0, 3))
21792179

21802180
@unittest.skipIf(linked_to_musl(), "musl libc issue, bpo-46390")
2181+
@unittest.skipIf(sys.platform.startswith("sunos"),
2182+
"test doesn't work on Solaris, gh-91214")
21812183
def test_locale_caching(self):
21822184
# Issue #22410
21832185
oldlocale = locale.setlocale(locale.LC_CTYPE)
@@ -2215,6 +2217,8 @@ def check_en_US_utf8(self):
22152217
self.assertIsNone(re.match(b'(?Li)\xe5', b'\xc5'))
22162218

22172219
@unittest.skipIf(linked_to_musl(), "musl libc issue, bpo-46390")
2220+
@unittest.skipIf(sys.platform.startswith("sunos"),
2221+
"test doesn't work on Solaris, gh-91214")
22182222
def test_locale_compiled(self):
22192223
oldlocale = locale.setlocale(locale.LC_CTYPE)
22202224
self.addCleanup(locale.setlocale, locale.LC_CTYPE, oldlocale)

Lib/test/test_socket.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252

5353
VSOCKPORT = 1234
5454
AIX = platform.system() == "AIX"
55+
SOLARIS = sys.platform.startswith("sunos")
5556
WSL = "microsoft-standard-WSL" in platform.release()
5657

5758
try:
@@ -3888,6 +3889,10 @@ def testCMSG_SPACE(self):
38883889
# Test CMSG_SPACE() with various valid and invalid values,
38893890
# checking the assumptions used by sendmsg().
38903891
toobig = self.socklen_t_limit - socket.CMSG_SPACE(1) + 1
3892+
if SOLARIS and platform.processor() == "sparc":
3893+
# On Solaris SPARC, number of bytes returned by socket.CMSG_SPACE
3894+
# increases at different lengths; see gh-91214.
3895+
toobig -= 3
38913896
values = list(range(257)) + list(range(toobig - 257, toobig))
38923897

38933898
last = socket.CMSG_SPACE(0)
@@ -4034,6 +4039,7 @@ def _testFDPassCMSG_LEN(self):
40344039
self.createAndSendFDs(1)
40354040

40364041
@unittest.skipIf(is_apple, "skipping, see issue #12958")
4042+
@unittest.skipIf(SOLARIS, "skipping, see gh-91214")
40374043
@unittest.skipIf(AIX, "skipping, see issue #22397")
40384044
@requireAttrs(socket, "CMSG_SPACE")
40394045
def testFDPassSeparate(self):
@@ -4045,6 +4051,7 @@ def testFDPassSeparate(self):
40454051

40464052
@testFDPassSeparate.client_skip
40474053
@unittest.skipIf(is_apple, "skipping, see issue #12958")
4054+
@unittest.skipIf(SOLARIS, "skipping, see gh-91214")
40484055
@unittest.skipIf(AIX, "skipping, see issue #22397")
40494056
def _testFDPassSeparate(self):
40504057
fd0, fd1 = self.newFDs(2)
@@ -4058,6 +4065,7 @@ def _testFDPassSeparate(self):
40584065
len(MSG))
40594066

40604067
@unittest.skipIf(is_apple, "skipping, see issue #12958")
4068+
@unittest.skipIf(SOLARIS, "skipping, see gh-91214")
40614069
@unittest.skipIf(AIX, "skipping, see issue #22397")
40624070
@requireAttrs(socket, "CMSG_SPACE")
40634071
def testFDPassSeparateMinSpace(self):
@@ -4072,6 +4080,7 @@ def testFDPassSeparateMinSpace(self):
40724080

40734081
@testFDPassSeparateMinSpace.client_skip
40744082
@unittest.skipIf(is_apple, "skipping, see issue #12958")
4083+
@unittest.skipIf(SOLARIS, "skipping, see gh-91214")
40754084
@unittest.skipIf(AIX, "skipping, see issue #22397")
40764085
def _testFDPassSeparateMinSpace(self):
40774086
fd0, fd1 = self.newFDs(2)

0 commit comments

Comments
 (0)