summaryrefslogtreecommitdiff
path: root/mysql-test/mysql-test-run.pl
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/mysql-test-run.pl')
-rwxr-xr-xmysql-test/mysql-test-run.pl44
1 files changed, 31 insertions, 13 deletions
diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl
index 8399c41b67b..cff6e9ecedd 100755
--- a/mysql-test/mysql-test-run.pl
+++ b/mysql-test/mysql-test-run.pl
@@ -160,7 +160,9 @@ my $path_config_file; # The generated config file, var/my.cnf
# executables will be used by the test suite.
our $opt_vs_config = $ENV{'MTR_VS_CONFIG'};
-my $DEFAULT_SUITES= "main,binlog,federated,rpl,maria,handler,parts,innodb,innodb_plugin,percona,ndb,vcol,oqgraph,sphinx,plugins";
+my $DEFAULT_SUITES="main,binlog,federated,rpl,maria,handler,parts,innodb," .
+ "innodb_plugin,percona,ndb,vcol,oqgraph,sphinx," .
+ "optimizer_unfixed_bugs,plugins";
my $opt_suites;
our $opt_verbose= 0; # Verbose output, enable with --verbose
@@ -337,9 +339,10 @@ sub main {
gcov_prepare($basedir . "/" . $opt_gcov_src_dir);
}
+
if (!$opt_suites) {
$opt_suites= $DEFAULT_SUITES;
-
+
# Check for any extra suites to enable based on the path name
my %extra_suites=
(
@@ -2091,6 +2094,13 @@ sub environment_setup {
push(@ld_library_paths, "$basedir/libmysql/.libs/",
"$basedir/libmysql_r/.libs/",
"$basedir/zlib/.libs/");
+ if ($^O eq "darwin")
+ {
+ # it is MAC OS and we have to add dynamic libraries paths
+ push @ld_library_paths, grep {<$_/*.dylib>}
+ (<$bindir/storage/*/.libs/>,<$bindir/plugin/*/.libs/>,
+ <$bindir/plugin/*/*/.libs/>,<$bindir/storage/*/*/.libs>);
+ }
}
else
{
@@ -2497,7 +2507,7 @@ sub setup_vardir() {
}
else
{
- for (<$bindir/storage/*/.libs/*.so>,<$bindir/plugin/*/.libs/*.so>,<$bindir/sql/.libs/*.so>)
+ for (<$bindir/storage/*/.libs/*.so>,<$bindir/plugin/*/.libs/*.so>,<$bindir/plugin/*/*/.libs/*.so>,<$bindir/sql/.libs/*.so>)
{
my $pname=basename($_);
symlink rel2abs($_), "$plugindir/$pname";
@@ -2508,7 +2518,8 @@ sub setup_vardir() {
else
{
# hm, what paths work for debs and for rpms ?
- for (<$bindir/lib/mysql/plugin/*.so>,
+ for (<$bindir/lib64/mysql/plugin/*.so>,
+ <$bindir/lib/mysql/plugin/*.so>,
<$bindir/lib/plugin/*.dll>)
{
my $pname=basename($_);
@@ -4362,8 +4373,9 @@ sub get_log_from_proc ($$) {
# error log and write all lines that look
# suspicious into $error_log.warnings
#
-sub extract_warning_lines ($) {
- my ($error_log) = @_;
+
+sub extract_warning_lines ($$) {
+ my ($error_log, $append) = @_;
# Open the servers .err log file and read all lines
# belonging to current tets into @lines
@@ -4400,9 +4412,12 @@ sub extract_warning_lines ($) {
# Write all suspicious lines to $error_log.warnings file
my $warning_log = "$error_log.warnings";
- my $Fwarn = IO::File->new($warning_log, "w")
+ my $Fwarn = IO::File->new($warning_log, $append ? "a+" : "w")
or die("Could not open file '$warning_log' for writing: $!");
- print $Fwarn "Suspicious lines from $error_log\n";
+ if (!$append)
+ {
+ print $Fwarn "Suspicious lines from $error_log\n";
+ }
my @patterns =
(
@@ -4461,6 +4476,7 @@ sub extract_warning_lines ($) {
qr|Checking table: '\..mtr.test_suppressions'|,
qr|Table \./test/bug53592 has a primary key in InnoDB data dictionary, but not in MySQL|,
qr|Table '\..mtr.test_suppressions' is marked as crashed and should be repaired|,
+ qr|Can't open shared library.*ha_archive|,
qr|InnoDB: Error: table 'test/bug39438'|,
qr|Access denied for user|,
qr|Aborted connection|,
@@ -4510,7 +4526,7 @@ sub start_check_warnings ($$) {
my $log_error= $mysqld->value('#log-error');
# To be communicated to the test
$ENV{MTR_LOG_ERROR}= $log_error;
- extract_warning_lines($log_error);
+ extract_warning_lines($log_error, 0);
my $args;
mtr_init_args(\$args);
@@ -4665,7 +4681,7 @@ sub check_warnings_post_shutdown {
foreach my $mysqld ( mysqlds())
{
my ($testlist, $match_lines)=
- extract_warning_lines($mysqld->value('#log-error'));
+ extract_warning_lines($mysqld->value('#log-error'), 1);
$testname_hash->{$_}= 1 for @$testlist;
$report.= join('', @$match_lines);
}
@@ -4976,6 +4992,8 @@ sub mysqld_arguments ($$$) {
mtr_add_arg($args, "--loose-skip-safemalloc");
mtr_add_arg($args, "%s--disable-sync-frm");
+ # Retry bind as this may fail on busy server
+ mtr_add_arg($args, "%s--port-open-timeout=10");
if (!using_extern() and $mysql_version_id >= 50106 && !$opt_user_args)
{
@@ -5134,10 +5152,10 @@ sub mysqld_start ($$) {
# Write a message about this to the normal log file
my $trace_name= "$opt_vardir/log/".$mysqld->name().".trace";
mtr_tofile($output,
- "NOTE: When running with --valgrind --debug the output from",
- "mysqld(where the valgrind messages shows up) is stored ",
+ "NOTE: When running with --valgrind --debug the output from ",
+ "mysqld (where the valgrind messages shows up) is stored ",
"together with the trace file to make it ",
- "easier to find the exact position of valgrind errors.",
+ "easier to find the exact position of valgrind errors. ",
"See trace file $trace_name.\n");
$output= $trace_name;