Bug #33300 no test cases for mysql_install_db
Submitted: 17 Dec 2007 21:33 Modified: 16 Sep 2008 4:20
Reporter: Mikael Ronström Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Installing Severity:S3 (Non-critical)
Version:5.0/5.1 OS:Any
Assigned to: Jonathan Perkin CPU Architecture:Any

[17 Dec 2007 21:33] Mikael Ronström
Description:
I've been hit by basic bugs in mysql_install_db twice.

The problem is that there is no test cases in the mysql-test-run suite that all
verifies this script.

How to repeat:
Put a bug in mysql_install_db and run mysql-test-run,
the test passes when it should return an error.

Suggested fix:
Write a test case in mysql-test-run for mysql_install_db
Actually more than one test case should be developed since there
are many code paths in the scripts.
[17 Dec 2007 21:58] MySQL Verification Team
Thank you for the bug report.
[18 Dec 2007 11:19] Daniel Fischer
make distcheck should verify this too
[18 Dec 2007 11:28] Mikael Ronström
Then I suggest make distcheck is put into some of the pushbuild clones.
[18 Dec 2007 11:39] Daniel Fischer
It is (on nocona). What I meant is that it should, but does not yet actually do, test mysql_install_db.
[7 Mar 2008 19:36] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/43619

ChangeSet@1.2590, 2008-03-07 19:35:38+00:00, jperkin@chorlton.adsl.perkin.org.uk +1 -0
  bug#33300: use myisamchk to verify that mysql_install_db has
  created at least some files and that they are correct.
[7 Mar 2008 19:45] Jonathan Perkin
The script is now checked as part of make distcheck by verifying the db files have been created correctly.  As for adding to mysql-test-run, I don't think that is suitable for testing the various ways mysql_install_db can be executed (notably, as part of a full 'make install' rather than running out of the source tree as distcheck does).

For basic errors in the script, I think the addition to distcheck will catch those, and should suffice.
[14 Apr 2008 20:08] Joerg Bruehe
Patch looks good, ok to push.

A real test of "mysql_install_db" does not belong into the test suite,
this would be part of the installation and upgrade/downgrade tests which the SystemQA team is working on.

It the reporter feels this test here is insufficient, the matter should be brought up with SystemQA.
[20 Aug 2008 14:56] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/52061

2790 Ramil Kalimullin	2008-08-20
      Merge error in federated.result fixed.
[21 Aug 2008 18:02] Bugs System
Pushed into 5.1.28  (revid:jperkin@sun.com-20080820113234-63l9tnqbycrdrxd7) (version source revid:azundris@mysql.com-20080821081500-f2d61fh4u61owz3p) (pib:3)
[14 Sep 2008 3:18] Bugs System
Pushed into 6.0.7-alpha  (revid:jperkin@sun.com-20080820113234-63l9tnqbycrdrxd7) (version source revid:sven@mysql.com-20080818175803-c1nutd5773r6b4gd) (pib:3)
[16 Sep 2008 4:20] Paul DuBois
No changelog entry needed.
[30 Sep 2008 13:26] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/54774

2667 He Zhenxing	2008-09-29 [merge]
      Auto Merge