diff options
Diffstat (limited to 'mysql-test/suite.pm')
-rw-r--r-- | mysql-test/suite.pm | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/mysql-test/suite.pm b/mysql-test/suite.pm index 7f676b7ccfd..d80b4aaf822 100644 --- a/mysql-test/suite.pm +++ b/mysql-test/suite.pm @@ -9,9 +9,9 @@ sub skip_combinations { # disable innodb/xtradb combinatons for configurations that were not built push @combinations, 'innodb_plugin' unless $ENV{HA_INNODB_SO}; - # if something is compiled in, it's innodb. xtradb is MODULE_ONLY: - push @combinations, 'innodb' unless $::mysqld_variables{'innodb'} eq "ON"; - push @combinations, 'xtradb'; + # if something is compiled in, it's xtradb. innodb is MODULE_ONLY: + push @combinations, 'xtradb' unless $::mysqld_variables{'innodb'} eq "ON"; + push @combinations, 'innodb'; # XtraDB is RECOMPILE_FOR_EMBEDDED, ha_xtradb.so cannot work with embedded server push @combinations, 'xtradb_plugin' if not $ENV{HA_XTRADB_SO} @@ -43,10 +43,14 @@ sub skip_combinations { unless $::mysqld_variables{'innodb'} eq "ON"; # disable tests that use ipv6, if unsupported - use Socket; - $skip{'include/check_ipv6.inc'} = 'No IPv6' - unless socket SOCK, PF_INET6, SOCK_STREAM, getprotobyname('tcp'); - close SOCK; + sub ipv6_ok() { + use Socket; + return 0 unless socket my $sock, PF_INET6, SOCK_STREAM, getprotobyname('tcp'); + # eval{}, if there's no Socket::sockaddr_in6 at all, old Perl installation + eval { connect $sock, sockaddr_in6(7, Socket::IN6ADDR_LOOPBACK) }; + return $! != 101; + } + $skip{'include/check_ipv6.inc'} = 'No IPv6' unless ipv6_ok(); %skip; } |