summaryrefslogtreecommitdiff
path: root/mysql-test/include
diff options
context:
space:
mode:
authorNirbhay Choubey <nirbhay@mariadb.com>2016-10-28 15:50:13 -0400
committerNirbhay Choubey <nirbhay@mariadb.com>2016-10-28 15:50:13 -0400
commit5db2195a35c0a2ee7703ab603721b2f0987d2585 (patch)
tree1306ce565f0f01f56dd31b2c43b1233bcb08257c /mysql-test/include
parentc9ded859a6fad25fc513d3a0c7d17f826e567691 (diff)
parenteca8c324e9a02f530853580991b11b587f54b24a (diff)
downloadmariadb-git-5db2195a35c0a2ee7703ab603721b2f0987d2585.tar.gz
Merge tag 'mariadb-10.0.28' into 10.0-galera
Diffstat (limited to 'mysql-test/include')
-rw-r--r--mysql-test/include/index_merge2.inc1
-rw-r--r--mysql-test/include/search_pattern_in_file.inc15
2 files changed, 10 insertions, 6 deletions
diff --git a/mysql-test/include/index_merge2.inc b/mysql-test/include/index_merge2.inc
index c50a45a9923..03afa49d323 100644
--- a/mysql-test/include/index_merge2.inc
+++ b/mysql-test/include/index_merge2.inc
@@ -341,6 +341,7 @@ while ($1)
alter table t1 add index i2(key2);
alter table t1 add index i3(key3);
update t1 set key2=key1,key3=key1;
+analyze table t1;
# to test the bug, the following must use "sort_union":
--replace_column 9 REF
diff --git a/mysql-test/include/search_pattern_in_file.inc b/mysql-test/include/search_pattern_in_file.inc
index 0d09cdcd36e..84237026ed0 100644
--- a/mysql-test/include/search_pattern_in_file.inc
+++ b/mysql-test/include/search_pattern_in_file.inc
@@ -60,12 +60,12 @@
perl;
use strict;
- my $search_file= $ENV{'SEARCH_FILE'} or die "SEARCH_FILE not set";
- my $search_pattern= $ENV{'SEARCH_PATTERN'} or die "SEARCH_PATTERN not set";
- my $search_range= $ENV{'SEARCH_RANGE'};
+ my $search_file= $ENV{'SEARCH_FILE'} or die "SEARCH_FILE not set";
+ my $search_pattern= $ENV{'SEARCH_PATTERN'} or die "SEARCH_PATTERN not set";
+ my $search_range= $ENV{'SEARCH_RANGE'};
my $file_content;
$search_range= 50000 unless $search_range =~ /-?[0-9]+/;
- open(FILE, "$search_file") or die("Unable to open '$search_file': $!\n");
+ open(FILE, '<', $search_file) or die("Unable to open '$search_file': $!\n");
if ($search_range >= 0) {
read(FILE, $file_content, $search_range, 0);
} else {
@@ -75,7 +75,10 @@ perl;
read(FILE, $file_content, -$search_range, 0);
}
close(FILE);
- if ( not $file_content =~ m{$search_pattern} ) {
- die("# ERROR: The file '$search_file' does not contain the expected pattern $search_pattern\n->$file_content<-\n");
+ $search_file =~ s{^.*?([^/\\]+)$}{$1};
+ if ($file_content =~ m{$search_pattern}) {
+ print "FOUND /$search_pattern/ in $search_file\n"
+ } else {
+ print "NOT FOUND /$search_pattern/ in $search_file\n"
}
EOF