Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
f972a086
Commit
f972a086
authored
Jan 26, 2005
by
mleich@mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge mleich@bk-internal.mysql.com:/home/bk/mysql-5.0
into mysql.com:/home/matthias/Arbeit/mysql-5.0/src
parents
6596744d
0e442f7c
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
52 additions
and
17 deletions
+52
-17
mysql-test/include/testdb_only.inc
mysql-test/include/testdb_only.inc
+30
-0
mysql-test/mysql-test-run.sh
mysql-test/mysql-test-run.sh
+20
-17
mysql-test/r/testdb_only.require
mysql-test/r/testdb_only.require
+2
-0
No files found.
mysql-test/include/testdb_only.inc
0 → 100644
View file @
f972a086
#################### include/testdb_only.inc ######################
# #
# We must prevent to work on databases created by customers, #
# because we DROP/CREATE/MODIFY objects with sometimes common #
# names like STAFF, EMPLOYEE etc. #
# #
# Therefore we check the environment variable USE_RUNNING_SERVER. #
# USE_RUNNING_SERVER is exported by "mysql-test-run" and could #
# contain the following values: #
# 0 -- mysql-test-run was started without the --extern option #
# That means the test will be performed within the test #
# area 'mysql-test/var/...' . #
# 1 -- mysql-test-run was started with the --extern option #
# That means the test will be performed by an already #
# running server and data modifications will most probably #
# outside of the common test area 'mysql-test/var/...' . #
# #
# If USE_RUNNING_SERVER is not 0 the test will be skipped. #
# #
###################################################################
--
disable_query_log
eval
set
@
USE_RUNNING_SERVER
=
'$USE_RUNNING_SERVER'
;
--
require
r
/
testdb_only
.
require
SELECT
'use extern server'
AS
"Variable_name "
,
IF
(
@
USE_RUNNING_SERVER
=
'1'
,
'YES'
,
IF
(
@
USE_RUNNING_SERVER
=
'0'
,
'NO'
,
'UNEXPECTED'
))
AS
"Value"
;
--
enable_query_log
mysql-test/mysql-test-run.sh
View file @
f972a086
...
@@ -224,7 +224,7 @@ EXTRA_MASTER_OPT=""
...
@@ -224,7 +224,7 @@ EXTRA_MASTER_OPT=""
EXTRA_MYSQL_TEST_OPT
=
""
EXTRA_MYSQL_TEST_OPT
=
""
EXTRA_MYSQLDUMP_OPT
=
""
EXTRA_MYSQLDUMP_OPT
=
""
EXTRA_MYSQLBINLOG_OPT
=
""
EXTRA_MYSQLBINLOG_OPT
=
""
USE_RUNNING_SERVER
=
""
USE_RUNNING_SERVER
=
0
USE_NDBCLUSTER
=
""
USE_NDBCLUSTER
=
""
USE_RUNNING_NDBCLUSTER
=
""
USE_RUNNING_NDBCLUSTER
=
""
DO_GCOV
=
""
DO_GCOV
=
""
...
@@ -255,7 +255,7 @@ NDBD_EXTRA_OPTS=
...
@@ -255,7 +255,7 @@ NDBD_EXTRA_OPTS=
while
test
$#
-gt
0
;
do
while
test
$#
-gt
0
;
do
case
"
$1
"
in
case
"
$1
"
in
--embedded-server
)
USE_EMBEDDED_SERVER
=
1
USE_MANAGER
=
0
NO_SLAVE
=
1
;
\
--embedded-server
)
USE_EMBEDDED_SERVER
=
1
USE_MANAGER
=
0
NO_SLAVE
=
1
;
\
USE_RUNNING_SERVER
=
""
RESULT_EXT
=
".es"
TEST_MODE
=
"embedded"
;;
USE_RUNNING_SERVER
=
0
RESULT_EXT
=
".es"
TEST_MODE
=
"embedded"
;;
--user
=
*
)
DBUSER
=
`
$ECHO
"
$1
"
|
$SED
-e
"s;--user=;;"
`
;;
--user
=
*
)
DBUSER
=
`
$ECHO
"
$1
"
|
$SED
-e
"s;--user=;;"
`
;;
--force
)
FORCE
=
1
;;
--force
)
FORCE
=
1
;;
--timer
)
USE_TIMER
=
1
;;
--timer
)
USE_TIMER
=
1
;;
...
@@ -265,8 +265,8 @@ while test $# -gt 0; do
...
@@ -265,8 +265,8 @@ while test $# -gt 0; do
MASTER_MYSQLD
=
`
$ECHO
"
$1
"
|
$SED
-e
"s;--master-binary=;;"
`
;;
MASTER_MYSQLD
=
`
$ECHO
"
$1
"
|
$SED
-e
"s;--master-binary=;;"
`
;;
--slave-binary
=
*
)
--slave-binary
=
*
)
SLAVE_MYSQLD
=
`
$ECHO
"
$1
"
|
$SED
-e
"s;--slave-binary=;;"
`
;;
SLAVE_MYSQLD
=
`
$ECHO
"
$1
"
|
$SED
-e
"s;--slave-binary=;;"
`
;;
--local
)
USE_RUNNING_SERVER
=
""
;;
--local
)
USE_RUNNING_SERVER
=
0
;;
--extern
)
USE_RUNNING_SERVER
=
"1"
;;
--extern
)
USE_RUNNING_SERVER
=
1
;;
--with-ndbcluster
)
--with-ndbcluster
)
USE_NDBCLUSTER
=
"--ndbcluster"
;;
USE_NDBCLUSTER
=
"--ndbcluster"
;;
--ndb-connectstring
=
*
)
--ndb-connectstring
=
*
)
...
@@ -303,7 +303,7 @@ while test $# -gt 0; do
...
@@ -303,7 +303,7 @@ while test $# -gt 0; do
--no-manager
|
--skip-manager
)
USE_MANAGER
=
0
;;
--no-manager
|
--skip-manager
)
USE_MANAGER
=
0
;;
--manager
)
--manager
)
USE_MANAGER
=
1
USE_MANAGER
=
1
USE_RUNNING_SERVER
=
USE_RUNNING_SERVER
=
0
;;
;;
--start-and-exit
)
--start-and-exit
)
START_AND_EXIT
=
1
START_AND_EXIT
=
1
...
@@ -372,7 +372,7 @@ while test $# -gt 0; do
...
@@ -372,7 +372,7 @@ while test $# -gt 0; do
EXTRA_SLAVE_MYSQLD_OPT
=
"
$EXTRA_SLAVE_MYSQLD_OPT
--gdb"
EXTRA_SLAVE_MYSQLD_OPT
=
"
$EXTRA_SLAVE_MYSQLD_OPT
--gdb"
# This needs to be checked properly
# This needs to be checked properly
# USE_MANAGER=1
# USE_MANAGER=1
USE_RUNNING_SERVER
=
""
USE_RUNNING_SERVER
=
0
;;
;;
--client-gdb
)
--client-gdb
)
if
[
x
$BINARY_DIST
=
x1
]
;
then
if
[
x
$BINARY_DIST
=
x1
]
;
then
...
@@ -385,7 +385,7 @@ while test $# -gt 0; do
...
@@ -385,7 +385,7 @@ while test $# -gt 0; do
--manual-gdb
)
--manual-gdb
)
DO_GDB
=
1
DO_GDB
=
1
MANUAL_GDB
=
1
MANUAL_GDB
=
1
USE_RUNNING_SERVER
=
""
USE_RUNNING_SERVER
=
0
EXTRA_MASTER_MYSQLD_OPT
=
"
$EXTRA_MASTER_MYSQLD_OPT
--gdb"
EXTRA_MASTER_MYSQLD_OPT
=
"
$EXTRA_MASTER_MYSQLD_OPT
--gdb"
EXTRA_SLAVE_MYSQLD_OPT
=
"
$EXTRA_SLAVE_MYSQLD_OPT
--gdb"
EXTRA_SLAVE_MYSQLD_OPT
=
"
$EXTRA_SLAVE_MYSQLD_OPT
--gdb"
;;
;;
...
@@ -394,7 +394,7 @@ while test $# -gt 0; do
...
@@ -394,7 +394,7 @@ while test $# -gt 0; do
$ECHO
"Note: you will get more meaningful output on a source distribution compiled with debugging option when running tests with --ddd option"
$ECHO
"Note: you will get more meaningful output on a source distribution compiled with debugging option when running tests with --ddd option"
fi
fi
DO_DDD
=
1
DO_DDD
=
1
USE_RUNNING_SERVER
=
""
USE_RUNNING_SERVER
=
0
EXTRA_MASTER_MYSQLD_OPT
=
"
$EXTRA_MASTER_MYSQLD_OPT
--gdb"
EXTRA_MASTER_MYSQLD_OPT
=
"
$EXTRA_MASTER_MYSQLD_OPT
--gdb"
EXTRA_SLAVE_MYSQLD_OPT
=
"
$EXTRA_SLAVE_MYSQLD_OPT
--gdb"
EXTRA_SLAVE_MYSQLD_OPT
=
"
$EXTRA_SLAVE_MYSQLD_OPT
--gdb"
;;
;;
...
@@ -412,7 +412,7 @@ while test $# -gt 0; do
...
@@ -412,7 +412,7 @@ while test $# -gt 0; do
EXTRA_SLAVE_MYSQLD_OPT
=
"
$EXTRA_SLAVE_MYSQLD_OPT
--skip-safemalloc --skip-bdb"
EXTRA_SLAVE_MYSQLD_OPT
=
"
$EXTRA_SLAVE_MYSQLD_OPT
--skip-safemalloc --skip-bdb"
SLEEP_TIME_AFTER_RESTART
=
10
SLEEP_TIME_AFTER_RESTART
=
10
SLEEP_TIME_FOR_DELETE
=
60
SLEEP_TIME_FOR_DELETE
=
60
USE_RUNNING_SERVER
=
""
USE_RUNNING_SERVER
=
0
if
test
"
$1
"
=
"--valgrind-all"
if
test
"
$1
"
=
"--valgrind-all"
then
then
VALGRIND
=
"
$VALGRIND
-v --show-reachable=yes"
VALGRIND
=
"
$VALGRIND
-v --show-reachable=yes"
...
@@ -627,9 +627,9 @@ fi
...
@@ -627,9 +627,9 @@ fi
if
[
-z
"
$1
"
]
if
[
-z
"
$1
"
]
then
then
USE_RUNNING_SERVER
=
""
USE_RUNNING_SERVER
=
0
fi
fi
if
[
-n
"
$USE_RUNNING_SERVER
"
]
if
[
$USE_RUNNING_SERVER
-eq
1
]
then
then
MASTER_MYSOCK
=
$LOCAL_SOCKET
;
MASTER_MYSOCK
=
$LOCAL_SOCKET
;
DBUSER
=
${
DBUSER
:-
test
}
DBUSER
=
${
DBUSER
:-
test
}
...
@@ -801,7 +801,7 @@ report_stats () {
...
@@ -801,7 +801,7 @@ report_stats () {
$ECHO
"http://www.mysql.com/doc/en/MySQL_test_suite.html"
$ECHO
"http://www.mysql.com/doc/en/MySQL_test_suite.html"
fi
fi
if
test
-z
"
$USE_RUNNING_SERVER
"
if
[
$USE_RUNNING_SERVER
-eq
0
]
then
then
# Report if there was any fatal warnings/errors in the log files
# Report if there was any fatal warnings/errors in the log files
...
@@ -1511,7 +1511,7 @@ run_testcase ()
...
@@ -1511,7 +1511,7 @@ run_testcase ()
done
done
fi
fi
if
[
-z
"
$USE_RUNNING_SERVER
"
]
;
if
[
$USE_RUNNING_SERVER
-eq
0
]
;
then
then
if
[
-f
$master_opt_file
]
;
if
[
-f
$master_opt_file
]
;
then
then
...
@@ -1655,7 +1655,7 @@ run_testcase ()
...
@@ -1655,7 +1655,7 @@ run_testcase ()
if
[
x
$FORCE
!=
x1
]
;
then
if
[
x
$FORCE
!=
x1
]
;
then
$ECHO
"Aborting:
$tname
failed in
$TEST_MODE
mode. To continue, re-run with '--force'."
$ECHO
"Aborting:
$tname
failed in
$TEST_MODE
mode. To continue, re-run with '--force'."
$ECHO
$ECHO
if
[
-z
"
$DO_GDB
"
]
&&
[
-z
"
$USE_RUNNING_SERVER
"
]
&&
\
if
[
-z
"
$DO_GDB
"
]
&&
[
$USE_RUNNING_SERVER
-eq
0
]
&&
\
[
-z
"
$DO_DDD
"
]
&&
[
-z
"
$USE_EMBEDDED_SERVER
"
]
[
-z
"
$DO_DDD
"
]
&&
[
-z
"
$USE_EMBEDDED_SERVER
"
]
then
then
mysql_stop
mysql_stop
...
@@ -1664,7 +1664,7 @@ run_testcase ()
...
@@ -1664,7 +1664,7 @@ run_testcase ()
exit
1
exit
1
fi
fi
FAILED_CASES
=
"
$FAILED_CASES
$tname
"
FAILED_CASES
=
"
$FAILED_CASES
$tname
"
if
[
-z
"
$DO_GDB
"
]
&&
[
-z
"
$USE_RUNNING_SERVER
"
]
&&
\
if
[
-z
"
$DO_GDB
"
]
&&
[
$USE_RUNNING_SERVER
-eq
0
]
&&
\
[
-z
"
$DO_DDD
"
]
&&
[
-z
"
$USE_EMBEDDED_SERVER
"
]
[
-z
"
$DO_DDD
"
]
&&
[
-z
"
$USE_EMBEDDED_SERVER
"
]
then
then
mysql_restart
mysql_restart
...
@@ -1683,7 +1683,7 @@ run_testcase ()
...
@@ -1683,7 +1683,7 @@ run_testcase ()
[
"
$DO_GCOV
"
]
&&
gcov_prepare
[
"
$DO_GCOV
"
]
&&
gcov_prepare
[
"
$DO_GPROF
"
]
&&
gprof_prepare
[
"
$DO_GPROF
"
]
&&
gprof_prepare
if
[
-z
"
$USE_RUNNING_SERVER
"
]
if
[
$USE_RUNNING_SERVER
-eq
0
]
then
then
if
[
-z
"
$FAST_START
"
]
if
[
-z
"
$FAST_START
"
]
then
then
...
@@ -1744,6 +1744,9 @@ fi
...
@@ -1744,6 +1744,9 @@ fi
$ECHO
"Starting Tests"
$ECHO
"Starting Tests"
# Some test cases need USE_RUNNING_SERVER
export
USE_RUNNING_SERVER
#
#
# This can probably be deleted
# This can probably be deleted
#
#
...
@@ -1816,7 +1819,7 @@ fi
...
@@ -1816,7 +1819,7 @@ fi
$ECHO
$DASH72
$ECHO
$DASH72
$ECHO
$ECHO
if
[
-z
"
$DO_GDB
"
]
&&
[
-z
"
$USE_RUNNING_SERVER
"
]
&&
[
-z
"
$DO_DDD
"
]
if
[
-z
"
$DO_GDB
"
]
&&
[
$USE_RUNNING_SERVER
-eq
0
]
&&
[
-z
"
$DO_DDD
"
]
then
then
mysql_stop
mysql_stop
fi
fi
...
...
mysql-test/r/testdb_only.require
0 → 100644
View file @
f972a086
Variable_name Value
use extern server NO
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment