Bjorn Munch
e3ca4792b7
Bug #13055685 NO WAY TO REPLACE NON-DETERMINISTIC FRAGMENTS IN OUTPUT OF MTR'S ECHO
...
Don't do this for echo, instead:
1) Enable replacements also for assignment from backquoted SQL
2) Allow replace_regex to take a variable for the *entire* argument list
With this, the test can be amended, but only in its version in trunk
2011-11-08 15:55:25 +01:00
sayantan.dutta@oracle.com
3068eee354
Bug #11754855 46528: NEED A WAY TO PASS A VARIABLE TO MTR COMMANDS
...
modified function do_get_error in mysqltest.cc to handle multiple variable passed
added test case to mysqltest.test to verify handling to multiple errors passed
2011-10-19 12:53:52 +05:30
Bjorn Munch
e08fa4affc
upmerge 12793118,12912120
2011-09-15 13:09:24 +02:00
Bjorn Munch
d75f2a4a6b
Bug #12793118 MYSQLTEST: --ERROR AND --DISABLE_ABORT_ON_ERROR DO NOT WORK FOR SQL IN COMMANDS
...
Call handle_error() instead of die() when evaluating these
Must remember "current command" with link to errors to ignore
Added test cases to mysqltest.test
2011-09-14 15:19:24 +02:00
Bjorn Munch
79b7d05c4c
Bug #12956584 MYSQLTEST: --ENABLE_X OR --DISABLE_X APPLYING ONLY TO NEXT COMMAND/STMT
...
Added a keyword ONCE to add to those commands
Some internal tables to keep track of which properties are
temporarily overriden
Added tests in mysqltest.test
Updates to other tests will be done later
2011-09-14 15:15:36 +02:00
Bjorn Munch
4ad7b28cd7
Bug #12793170 MYSQLTEST: PROVIDE ACCESS TO ERROR NAMES THROUGH NUMERIC CODES AND VICE VERSA
...
Added a second internal variable $mysql_errname
This is set the same way as $mysql_errno
Can be used like "if ($mysql_errname == ER_NO_SUCH_TABLE)...."
2011-08-22 13:58:49 +02:00
Bjorn Munch
3494a915fa
upmerge 58896,58900,59002
2011-01-11 15:15:25 +01:00
Bjorn Munch
0630418539
Bug #58900 query_get_value crashes when result begins with dollar sign
...
Generalized fix for recursive backtick
Optional arg to eval_expr telling it not to interpret
2011-01-11 10:54:42 +01:00
Bjorn Munch
453d4fab7b
merge from 5.5 main
2010-12-17 10:37:46 +01:00
Georgi Kodinov
7bdecb1d4a
merge
2010-12-16 16:40:52 +02:00
Bjorn Munch
f072749e06
upmerge 58511,58522,58608,58092
2010-12-09 15:32:39 +01:00
Bjorn Munch
955f42588e
Bug #58695 mysqltest coredumps on "if($x == ){"
...
Add check that there is a RHS of the expression
Added to mysqltest.test
2010-12-09 12:15:25 +01:00
Bjorn Munch
9dca123d02
Bug #58092 Test "rpl_cross_version" has "copy_file" failing
...
I am not fixing the test failure
Adds printing of my_errno when commands fail, could hopefully help
2010-12-01 11:11:16 +01:00
Bjorn Munch
20851e4012
Bug #58412 mysqltest: allow quoting of strings in let and in if comparison
...
Stripping quotes in let was a bad idea, will not fix
Added code to strip quotes from rhs in comparisons
2010-11-26 10:57:01 +01:00
Ramil Kalimullin
cc5263b223
Manual merge from mysql-5.5-bugteam.
2010-11-22 14:47:28 +03:00
Ramil Kalimullin
0628752fe9
Manual-merge from mysql-5.1-bugteam.
2010-11-22 12:21:10 +03:00
Bjorn Munch
374c6447ca
upmerge 58257
2010-11-18 16:41:35 +01:00
Bjorn Munch
d718af063e
Bug #58257 mysqltest: in if(), ! $var with space is always false
...
Evaluation would start with the space and thus ignore the $
Added while() to skip past white space
2010-11-17 16:05:52 +01:00
Bjorn Munch
f6b1d5a63e
upmerge 58087
2010-11-17 11:18:52 +01:00
Bjorn Munch
0f551def8f
Tests: many if/while expresissons simplified after 57276
2010-11-17 11:16:13 +01:00
Mattias Jonsson
7dde08a842
merge
2010-11-17 10:41:54 +01:00
Mattias Jonsson
d25e3389f4
post-push fix, backported --replace_result patch
...
for --list_files in mysqltest.
2010-11-17 10:13:57 +01:00
Bjorn Munch
9142f7462b
Bug #58087 mysqltest re-evaluates 'let' expressions infinitely
...
Results from query is sent for evaluation
Break recursion by asking for ` to be ignored
2010-11-15 14:23:02 +01:00
Bjorn Munch
28f60d525a
Bug #57276 mysqltest: add support for simple compares in if/while conditions
...
Added more parsing in do_block()
Limitation: left operand must be variable
Also changed var_set_int from 57036 to var_check_int
Added tests to mysqltest.test
Some tests can now be simplified but will take this later
Updated after comments, now white space around operator not needed
2010-11-10 09:42:14 +01:00
Bjorn Munch
3b15deb152
upmerge 56654
2010-10-19 14:13:05 +02:00
Bjorn Munch
e85b54a404
Bug #52828 Tests that use perl fail when perl is not in path
...
main.mysqltest skipped on Windows because a perl intentionally does exit(1)
Use exit(2), as exit(1) on Windows is indistinguishable from failing to
execute perl.
2010-10-19 13:56:30 +02:00
Bjorn Munch
cf362a41b9
upmerge 56125,56921
2010-09-28 16:00:11 +02:00
Bjorn Munch
3a404d4966
Bug #57036 Add checks in mysqltest that variables treated as ints are in fact ints
...
Adds boolean flag is_int and a separete function to check for int value
Added tests to mysqltest.test
2010-09-27 14:36:16 +02:00
Bjorn Munch
80d666bc21
Bug #56921 It should be possible to log connection statements in mysqltest
...
Added --enable-connect-log, somewhet similar to --enable-query-log
If query log is disabled, disable connect log too
Also some related cleanup in mysqltest.test: removing duplicate test loop
2010-09-22 10:57:10 +02:00
Bjorn Munch
8102240ce9
test fixes after 56753
2010-09-21 11:16:20 +02:00
Bjorn Munch
38604de3a0
Bug #56753 mtr silently ignores junk after backticks
...
When stepping backward to end of `` expression, check for illegal chars
2010-09-15 14:56:22 +02:00
Bjorn Munch
3ca814b760
Bug #55413 mysqltest gives parse error for lines matching "^let.*\\.*;$"
...
Allow escaped quotes also in statements not starting with --
But will not support single unescaped ' or `
2010-08-10 12:13:58 +02:00
Bjorn Munch
0792d2b069
Bug #55582 mtr root detection (and if-expression execution) broken
...
Follow-up patch: added test cases for -0 and while
2010-08-04 10:52:45 +02:00
Bjorn Munch
1ba9d79b7b
Bug #55582 mtr root detection (and if-expression execution) broken
...
if() treated any non-numeric string as false
Fixed to treat those as true instead
Added some test cases
Fixed missing $ in variable name in include/mix2.inc
2010-08-03 16:11:23 +02:00
Bjorn Munch
d7f2f03441
Bug #43603 mysqltest command disable_abort_on_error does not affect all built-in commands
...
After disable_abort_on_error, behaved as if --error was in effect
Add condition before die, as after queries
2010-03-22 11:28:57 +01:00
Bjorn Munch
2fb8854aa0
Bug #43588 mysqltest command disable_abort_on_error logs connect commands
...
Only log connects after --error
A few small test adjustments needed/possible
2010-03-17 15:25:55 +01:00
Bjorn Munch
68297e3ece
followup test fix after 49761
2010-03-03 11:17:00 +01:00
Bjorn Munch
3facbf180b
Bug #51590 mysqltest: --disable_abort_on_error does not work inside while/if
...
abort_on_error flag for stmt was set at initial parse
(Re)-set flag before execution instead, also added to test
2010-03-02 12:39:32 +01:00
Bjorn Munch
1f97527aaa
Bug #50618 Please allow 'sleep $variable' in mtr
...
Made mtr's sleep function understand $variables
A few fixes since previous patch, added tests
2010-02-09 18:13:57 +01:00
Bjorn Munch
ad89fa1bcd
Bug #39774 mysql-test-run's remove_file can't use wildcards, this should be documented
...
Added remove_files_wildcard that allows to remove multiple files at once.
This is a port of original patch to Windows.
2010-02-04 13:15:42 +01:00
Bjorn Munch
acc2b1ba6f
merge 49837
2010-01-20 14:23:57 +01:00
Bjorn Munch
21f728d94c
merge 48888
2010-01-20 14:22:34 +01:00
Bjorn Munch
37dc5f082a
Bug #49878 delimiter under false 'if' makes mysqltest test fail with 'Missing end of block'
...
delimiter not executed so does not recognize end of block
Always execute delimiter command, revert after false if() block.
2010-01-20 14:18:27 +01:00
Bjorn Munch
35d0d10ac2
Bug #48888 mysqltest crashes on --replace_result if 'from' is longer than ~1024 symbols
...
valgrind pointed to a buffer allocated by my_realloc which looked fishy
Replaced size with what was probably intended, added test case.
Now also fixed line after review comment
2010-01-20 12:52:35 +01:00
Bjorn Munch
128216d35b
Bug #49837 mysqltest exec cannot handle multi-line command correctly
...
Since the exec command line is passed on externally, it cannot take newlines
Simply replace \n with space
Now also added test case
2010-01-20 12:51:18 +01:00
Bjorn Munch
9ab9c73a87
Bug #49269 mysqltest crashes on 'reap' if query executed after 'send'
...
Undid amendment allowing pending reap after switching connections
Moved check for pending reap earlier; failed if running with ps-protocol
2010-01-07 11:22:45 +01:00
Bjorn Munch
570ee4c5e8
Bug #49269 mysqltest crashes on 'reap' if query executed after 'send'
...
Small amendment: ignore pending reap when switching connection, add test
2010-01-06 12:56:22 +01:00
Bjorn Munch
385f3f87c9
Bug #49761 mysqltest.test does not have any tests for send/reap
...
Added them
NB the 6th case is adapted to Bug no. 49269, gives wrong output without it
2010-01-06 09:47:25 +01:00
Bjorn Munch
2ec01d90d8
Bug #48863 mysql test: enable and disable case insensitive compare mode
...
Implemented --lowercase_result which lower cases next result
2010-01-06 09:42:21 +01:00
Bjorn Munch
ffdb6be755
Bug #48671 mysqltest fails on 'perl' in file sourced inside 'while'
...
Actually, fails on 'perl' in any while
Fixed essentially the same way as for append_file
2009-11-11 12:46:19 +01:00