Commit 5adeda3a authored by Mayank Prasad's avatar Mayank Prasad

BUG#12561297:LIBMYSQLD/EXAMPLE/MYSQL_EMBEDDED IS ABORTING.

Issue:
------
New test case mysql_embedded.test was failing on pb2.

Description:
------------
To run this test case executable libmysqld/examples/mysql_embedded is required.
But as per /libmysqld/examples/cmake_install.cmake this executable doesn't get
copied to <install_dir> when mysql is installed at <install_dir>.That is the
reason it was passing in my local branch and failed on pb2 when pushed.

Solution;
---------
Added code in mysql-test-run.pl, which will try to see if this file exists.If
It doesn't exist, test case will be skipped with a skip message. New code in
mysql-test-run.pl looks only for directory libmysqld/examples/mysql_embedded
because this is the only place where this file could/does exist.

mysql-test/mysql-test-run.pl:
  Added new variable for mysql_embedded executable.
mysql-test/t/disabled.def:
  enabled mysql_embedded.test which was disabled earlier.
mysql-test/t/mysql_embedded.test:
  Modified test case to first verify if mysql_embedded executable exists. If
  it does not, skip the test.
parent 1ba283a9
...@@ -171,6 +171,7 @@ our $exe_mysql; ...@@ -171,6 +171,7 @@ our $exe_mysql;
our $exe_mysqladmin; our $exe_mysqladmin;
our $exe_mysqltest; our $exe_mysqltest;
our $exe_libtool; our $exe_libtool;
our $exe_mysql_embedded;
our $opt_big_test= 0; our $opt_big_test= 0;
...@@ -1950,6 +1951,8 @@ sub executable_setup () { ...@@ -1950,6 +1951,8 @@ sub executable_setup () {
$exe_mysqladmin= mtr_exe_exists("$path_client_bindir/mysqladmin"); $exe_mysqladmin= mtr_exe_exists("$path_client_bindir/mysqladmin");
$exe_mysql= mtr_exe_exists("$path_client_bindir/mysql"); $exe_mysql= mtr_exe_exists("$path_client_bindir/mysql");
$exe_mysql_embedded= mtr_exe_maybe_exists("$basedir/libmysqld/examples/mysql_embedded");
if ( ! $opt_skip_ndbcluster ) if ( ! $opt_skip_ndbcluster )
{ {
# Look for single threaded NDB # Look for single threaded NDB
...@@ -2354,6 +2357,7 @@ sub environment_setup { ...@@ -2354,6 +2357,7 @@ sub environment_setup {
$ENV{'MYSQLADMIN'}= native_path($exe_mysqladmin); $ENV{'MYSQLADMIN'}= native_path($exe_mysqladmin);
$ENV{'MYSQL_CLIENT_TEST'}= mysql_client_test_arguments(); $ENV{'MYSQL_CLIENT_TEST'}= mysql_client_test_arguments();
$ENV{'EXE_MYSQL'}= $exe_mysql; $ENV{'EXE_MYSQL'}= $exe_mysql;
$ENV{'MYSQL_EMBEDDED'}= $exe_mysql_embedded;
# ---------------------------------------------------- # ----------------------------------------------------
# bug25714 executable may _not_ exist in # bug25714 executable may _not_ exist in
......
...@@ -16,4 +16,3 @@ alter_table-big : Bug#11748731 2010-11-15 mattiasj was not tested ...@@ -16,4 +16,3 @@ alter_table-big : Bug#11748731 2010-11-15 mattiasj was not tested
create-big : Bug#11748731 2010-11-15 mattiasj was not tested create-big : Bug#11748731 2010-11-15 mattiasj was not tested
archive-big : Bug#11817185 2011-03-10 Anitha Disabled since this leads to timeout on Solaris Sparc archive-big : Bug#11817185 2011-03-10 Anitha Disabled since this leads to timeout on Solaris Sparc
log_tables-big : Bug#11756699 2010-11-15 mattiasj report already exists log_tables-big : Bug#11756699 2010-11-15 mattiasj report already exists
mysql_embedded : Bug#12561297 2011-06-15 New test failing on all platforms
...@@ -3,4 +3,10 @@ ...@@ -3,4 +3,10 @@
--echo # --echo #
--source include/is_embedded.inc --source include/is_embedded.inc
--exec $MYSQL_TEST_DIR/../libmysqld/examples/mysql_embedded -e 'select 1'
# Test case require mysql_embedded to be present
if(!$MYSQL_EMBEDDED)
{
--skip Test requires mysql_embedded executable
}
--exec $MYSQL_EMBEDDED -e 'select 1'
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment