Description:
If a connection is defined in a mysqltest 'test' file and later is called with a training space, the test will fail and with a "connection 'xxx ' not found in connection pool.
This is a regression from previous releases, change happened somewhere between 5.0.78 (works ok) to 5.0.85 (fail). Not sure when the change happens in terms of 5.1 and later versions.
Workaround is to change the the 'connection' command and remove the trailing space
How to repeat:
CREATE USER omer1@localhost identified by 'PWD';
grant ALL ON *.* to omer1@localhost with grant option;
connect (OMR1,localhost,omer1,PWD,test);
show databases;
connection OMR1 ; <-- note the space between '1' and the ;
show grants;
Save the above in a test file in the 't' directory (bug.test)
Create an empty file bug.result in the 'r' directory
Run perl ./mysql-test-run.pl --do-test=bug
Using a 5.0.78 mysqltest binary (executed properly):
--- /data1/sumisho_5087/bin64_5087/mysql-test/r/omer1.result 2009-11-25 17:14:38.000000000 +0300
+++ /data1/sumisho_5087/bin64_5087/mysql-test/r/omer1.reject 2009-11-25 17:15:57.000000000 +0300
@@ -0,0 +1,10 @@
+CREATE USER omer1@localhost identified by 'PWD';
+grant ALL ON *.* to omer1@localhost with grant option;
+show databases;
+Database
+information_schema
+mysql
+test
+show grants;
+Grants for omer1@localhost
+GRANT ALL PRIVILEGES ON *.* TO 'omer1'@'localhost' IDENTIFIED BY PASSWORD '*C49735D016A099C0CF104EF9183F374A54CA2576' WITH GRANT OPTION
Using a 5.0.87 mysqltest program (breaks on the 'connection' command:
mysqltest: At line 5: connection 'OMR1 ' not found in connection pool
The result from queries just before the failure was:
CREATE USER omer1@localhost identified by 'PWD';
grant ALL ON *.* to omer1@localhost with grant option;
show databases;
Database
information_schema
mysql
test
Suggested fix:
Return previous behavior