@@ -41,9 +41,11 @@ def tearDownModule():
41
41
asyncio .set_event_loop_policy (None )
42
42
43
43
44
- def osx_tiger ():
44
+ def broken_unix_getsockname ():
45
45
"""Return True if the platform is Mac OS 10.4 or older."""
46
- if sys .platform != 'darwin' :
46
+ if sys .platform .startswith ("aix" ):
47
+ return True
48
+ elif sys .platform != 'darwin' :
47
49
return False
48
50
version = platform .mac_ver ()[0 ]
49
51
version = tuple (map (int , version .split ('.' )))
@@ -617,7 +619,7 @@ def test_create_connection(self):
617
619
def test_create_unix_connection (self ):
618
620
# Issue #20682: On Mac OS X Tiger, getsockname() returns a
619
621
# zero-length address for UNIX socket.
620
- check_sockname = not osx_tiger ()
622
+ check_sockname = not broken_unix_getsockname ()
621
623
622
624
with test_utils .run_test_unix_server () as httpd :
623
625
conn_fut = self .loop .create_unix_connection (
@@ -748,7 +750,7 @@ def test_create_ssl_connection(self):
748
750
def test_create_ssl_unix_connection (self ):
749
751
# Issue #20682: On Mac OS X Tiger, getsockname() returns a
750
752
# zero-length address for UNIX socket.
751
- check_sockname = not osx_tiger ()
753
+ check_sockname = not broken_unix_getsockname ()
752
754
753
755
with test_utils .run_test_unix_server (use_ssl = True ) as httpd :
754
756
create_connection = functools .partial (
0 commit comments