# http://module-build.sourceforge.net/META-spec.html
#XXXXXXX This is a prototype!!! It will change in the future!!! XXXXX#
name: Maypole
-version: 2.11_pre4
+version: 2.11_pre5
version_from: lib/Maypole.pm
installdirs: site
requires:
Class::DBI::Pager: 0
Class::DBI::Plugin::RetrieveAll: 0
Class::DBI::Plugin::Type: 0
- Class::DBI::SQLite: 0
+ Class::DBI::SQLite: 0.08
Digest::MD5: 0
File::MMagic::XS: 0.08
HTML::Element: 0
$DB_Class = 'BeerDB::BeerTestmysql';
-my $drh = DBI->install_driver("mysql");
-my %databases = map { $_ => 1 } $drh->func('localhost', 3306, '_ListDBs');
+my $drh = eval { DBI->install_driver("mysql"); };
+$err = $@;
+if ($err) {
+ $skip_msg = "no driver for MySQL";
+} else {
+ my %databases = map { $_ => 1 } $drh->func('localhost', 3306, '_ListDBs');
-unless ($databases{test}) {
- my $rc = $drh->func("createdb", 'test', 'admin');
-}
+ unless ($databases{test}) {
+ my $rc = $drh->func("createdb", 'test', 'admin');
+ }
-%databases = map { $_ => 1 } $drh->func('localhost', 3306, '_ListDBs');
+ %databases = map { $_ => 1 } $drh->func('localhost', 3306, '_ListDBs');
-if ($databases{test}) {
- eval {$DB_Class->connection("dbi:mysql:$db", "$dbuser", "$dbpasswd"); };
- $err = $@;
- $skip_msg = "Could not connect to MySQL using database 'test', username 'test', and password ''. Check privileges and try again.";
-} else {
- $err = 'no test db';
- $skip_msg = "Could not connect to MySQL using database 'test' as it doesn't exist, sorry";
+ if ($databases{test}) {
+ eval {$DB_Class->connection("dbi:mysql:$db", "$dbuser", "$dbpasswd"); };
+ $err = $@;
+ $skip_msg = "Could not connect to MySQL using database 'test', username 'test', and password ''. Check privileges and try again.";
+ } else {
+ $err = 'no test db';
+ $skip_msg = "Could not connect to MySQL using database 'test' as it doesn't exist, sorry";
+ }
}
-
$skip_howmany = 22;
SKIP: {