From: Stewart Smith Date: April 21 2008 5:55pm Subject: [PATCH] mysql-test-run suites for engines (nicley) List-Archive: http://lists.mysql.com/maria/12 Message-Id: <1208800508.22239.46.camel@willster> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-AWBuIW/skCzyKMwV8b53" --=-AWBuIW/skCzyKMwV8b53 Content-Type: text/plain Content-Transfer-Encoding: quoted-printable (free row of seats on plane... extended battery... not in the right timezone... so hacking at what should be 3:30am) Anyway.... I dislike how engines have to either put all their mysql-test-run tests in the mysql-test/suite storage/$engine/mysql-test-suites/$suite_name/[t|r] e.g. PBXT may have: storage/pbxt/mysql-test-suites/pbxt_basic (with t/ and r/) storage/pbxt/mysql-test-suites/pbxt_advanced (with t/ and r/) storage/pbxt/mysql-test-suites/pbxt_torture (with t/ and r/) storage/pbxt/mysql-test-suites/pbxt_mtr (with t/ and r/) the idea being you just plonk the storage engine in the storage/ directory and build the server! (I haven't fixed it up to install the right plugin yet... so you have to have your engine built into the server). I've fixed PBXT and federatedX to do this... Maria already does. Thoughts? (testing is welcome :) =3D=3D=3D=3D=3D mysql-test/lib/mtr_cases.pl 1.66 vs edited =3D=3D=3D=3D=3D --- 1.66/mysql-test/lib/mtr_cases.pl 2008-02-06 02:07:54 +11:00 +++ edited/mysql-test/lib/mtr_cases.pl 2008-04-22 03:34:58 +10:00 @@ -217,8 +217,15 @@ my $suitedir=3D "$::glob_mysql_test_dir"; # Default if ( $suite ne "main" ) { + my $storagedir=3D "$::glob_basedir/storage"; + opendir(DIR, $storagedir) || die "can't opendir $storagedir: $!"; + my @se_tests =3D grep { /^[^\.]/ && -d "$storagedir/$_/mysql-test-suit= es/" } readdir(DIR); + closedir DIR; + $_=3D"$storagedir/$_/mysql-test-suites/$suite" foreach(@se_tests); + mtr_verbose("looking for suitedir in @se_tests"); + $suitedir=3D mtr_path_exists("$suitedir/suite/$suite", - "$suitedir/$suite"); + "$suitedir/$suite",@se_tests); mtr_verbose("suitedir: $suitedir"); } =20 --=20 Stewart Smith, Senior Software Engineer (MySQL Cluster) Sun Microsystems Inc Office: +14082136540 Ext: 6616 VoIP: 6616@stripped Mobile: +61 4 3 8844 332 --=-AWBuIW/skCzyKMwV8b53 Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) iQIVAwUASAzU/L3yNwHyU3DLAQJTDxAAn0T3heYdKrmZvewnl9/YALQkZcsMjV3k ON68/pgtvmq9HjSdlK7zXgc463iUgKXCU5hbBaESAITS6ovpQMpBCfCYc1PKDFgq SFBv8UtjMIOCTPg4GyQexJGPJrYdpVmX6cWg7I+c75q97xSeyPfH//fNF83kdxPv 9d0iFVpy3/Rtca233I3VoQF39yIHIOLIhajpSFn0s/FOUmaKBfxhxHmwGLVcdOwZ +iaaVzQl2W1RhEIE68ZSxZuc0xMnfHtFxT5DLAKa1+eVoxJFpn50FQVA2yfNqQo1 ioQ8LaZ752XkJi7xz7RiIIcL2XEJEmh6GQKYwEGt4bnUtCapr8VXWe143fRBolHS NSYO68U0y9hUGqZtEY0hCL0IAoggrLIW7aEpryX4M4C5N1ZY3lnuIDBM7u0TlFJ8 J0vyPzCw3VNK1fMKywpNY505hUYGyRLki0B5dP155+XGoAKvYjf7uEYg9N4J2NkY /qbYlhhis051eTtM6Hg5FEVLdadNjnfP4Uk8bHzQiNdJWDdH1VJvkWty8Be4K/TC fm1aZV2dKXKkpAye6LVA8RxFHwHu7nbuaLCkjaghz0KS8A1vJRwl1bGuCWPKwUSD MJCz89vJnv9q7LJUIV0onPLx9jy1c7SwPL7DEXMAv9eMNTgkAr8BIiK3RCVAYWn9 uZYlcpzP7PE= =pfMX -----END PGP SIGNATURE----- --=-AWBuIW/skCzyKMwV8b53--