diff options
author | Yusuke Endoh <mame@ruby-lang.org> | 2020-02-13 23:13:17 +0900 |
---|---|---|
committer | Yusuke Endoh <mame@ruby-lang.org> | 2020-02-13 23:13:17 +0900 |
commit | bbc67993344830c18b15f5d90febc7dec9c87b3c (patch) | |
tree | a739c2a67c53f2985805d5a9ceabdc02eef16106 /spec/ruby | |
parent | 09a042ae0445472d42f35b9fd50c21d6564b0ece (diff) | |
download | ruby-bbc67993344830c18b15f5d90febc7dec9c87b3c.tar.gz |
spec/ruby/library/socket/addrinfo/getnameinfo_spec.rb: skip on Android
FreeBSD's GETNAMEINFO(3) says:
> If a link-layer address or UNIX-domain address is passed to
> getnameinfo(), its ASCII representation will be stored in host. The
> string pointed to by serv will be set to the empty string if non-NULL;
> flags will always be ignored.
Android seems to behave like FreeBSD.
Diffstat (limited to 'spec/ruby')
-rw-r--r-- | spec/ruby/library/socket/addrinfo/getnameinfo_spec.rb | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/spec/ruby/library/socket/addrinfo/getnameinfo_spec.rb b/spec/ruby/library/socket/addrinfo/getnameinfo_spec.rb index c5284f1c0f..76579de74c 100644 --- a/spec/ruby/library/socket/addrinfo/getnameinfo_spec.rb +++ b/spec/ruby/library/socket/addrinfo/getnameinfo_spec.rb @@ -21,18 +21,20 @@ describe 'Addrinfo#getnameinfo' do end platform_is :linux do - with_feature :unix_socket do - describe 'using a UNIX Addrinfo' do - before do - @addr = Addrinfo.unix('cats') - @host = Socket.gethostname - end + platform_is_not :android do + with_feature :unix_socket do + describe 'using a UNIX Addrinfo' do + before do + @addr = Addrinfo.unix('cats') + @host = Socket.gethostname + end - it 'returns the hostname and UNIX socket path' do - host, path = @addr.getnameinfo + it 'returns the hostname and UNIX socket path' do + host, path = @addr.getnameinfo - host.should == @host - path.should == 'cats' + host.should == @host + path.should == 'cats' + end end end end |