[CDBI] Re: Class::DBI and DBD::Mock problem

Aaron Trevena aaron.trevena at gmail.com
Tue Mar 20 15:15:57 GMT 2007

On 20/03/07, Aaron Trevena <aaron.trevena at gmail.com> wrote:
> I'm trying to unit test some hairy query autogeneration using Traits
> and Class::DBI - the obvious thing to do is to use DBD::Mock and
> populate some fake results, and check the params and statement
> provided.
> Unfortunately I get the following error when using DBD::Mock in place
> of a real driver :
> DBI bind_columns: invalid number of arguments: got handle + 0,
> expected handle + between 1 and -1
> Usage: $h->bind_columns(\$var1 [, \$var2, ...]) at
> /usr/lib/perl5/site_perl/5.8.5/Class/DBI.pm line 1140.
> when calling sth_to_objects, which I've over-ridden to do :

The same error occurs when I remove my sth_to_objects sub.. *sigh*


LAMP System Integration, Development and Hosting

More information about the ClassDBI mailing list