On 4/30/07, Dan Boger <[EMAIL PROTECTED]> wrote:
The error I'm seeing:
apocalypse$ prove -v t/Peeron2/ActivityLog.t
t/Peeron2/ActivityLog....ok 1 - Old log test entries not found
Can't use string ("Peeron2::Schema::ActivityLog") as a HASH ref while "strict
refs" in use at /usr/lib/perl5/site_perl/5.8.5/DBIx/Class/Row.pm line 97.
1..1
# Looks like your test died just after 1.
...
sub new {
my ($self, $attrs) = @_;
$attrs->{unixtime} = time if not $attrs->{unixtime} or $attrs->{unixtime}
=~ /\D/;
$attrs->{date} = sprintf("%04d-%02d-%02d", (localtime)[5]+1900,
(localtime)[4]+1, (localtime)[3])
unless $attrs->{date} and $attrs->{date} =~ /^\d\d\d\d-\d\d-\d\d$/;
$self->next::method($attrs);
return $self;
}
Either $self = $self->next::method( $attrs ), or remove your return
(thus returning the last value of next::method).
_______________________________________________
List: http://lists.rawmode.org/cgi-bin/mailman/listinfo/dbix-class
Wiki: http://dbix-class.shadowcatsystems.co.uk/
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/trunk/DBIx-Class/
Searchable Archive: http://www.mail-archive.com/dbix-class@lists.rawmode.org/