Skip Menu |

This queue is for tickets about the Test-Database CPAN distribution.

Report information
The Basics
Id: 94368
Status: open
Priority: 0/
Queue: Test-Database

People
Owner: Nobody in particular
Requestors: CHORNY [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 1.112
Fixed in: (no value)



Subject: handle->driver is undef
Apache::Session uses Test::Database and test fails http://www.cpantesters.org/cpan/report/6daeda46-b113-11e3-821a-9b76330ec7e2 Error is repeatable. Code of test: https://metacpan.org/source/CHORNY/Apache-Session-1.92/t/99mysql.t Tries this test program: use 5.012; use warnings; use Test::Database; my @db_handles = Test::Database->handles('mysql'); my $mysql = $db_handles[0]; say "DBD::mysql version ".DBD::mysql->VERSION(); say "mysql driver is undef " if !defined($mysql->driver); say "Mysql version ".$mysql->driver->version; it returns DBD::mysql version 4.026 mysql driver is undef Can't call method "version" on an undefined value at /media/sf_share/d.pl line 10. config file: dsn = dbi:mysql:database=testdb;host=... username = ... password = ... -- Alexandr Ciornii, http://chorny.net
Check your permssions on the /tmp/Test-Database-<username>/mysql directory/file. I had a similar problem and discovered I'd accidentally created the /tmp/Test-Database-barbie directory as root, and then was trying to create a database as my own user. After chown-ing the directory all worked fine.