sub insert {
my ($self, $ident, $to_insert) = @_;
$self->throw( "Couldn't insert ".join(', ', map "$_ => $to_insert->{$_}", keys %$to_insert)." into ${ident}" )
- unless ($self->_execute('insert' => [], $ident, $to_insert) > 0);
+ unless ($self->_execute('insert' => [], $ident, $to_insert));
return $to_insert;
}
--- /dev/null
+use Class::C3;
+use strict;
+use Test::More;
+use warnings;
+
+BEGIN {
+ eval "use DBD::SQLite";
+ plan $@
+ ? ( skip_all => 'needs DBD::SQLite for testing' )
+ : ( tests => 3 );
+}
+
+use lib qw(t/lib);
+
+use_ok( 'DBICTest' );
+
+use_ok( 'DBICTest::Schema' );
+
+{
+ my $warnings;
+ local $SIG{__WARN__} = sub { $warnings .= $_[0] };
+ eval { DBICTest::CD->create({ title => 'vacation in antarctica' }) };
+ ok( $warnings !~ /uninitialized value/, "No warning from Storage" );
+}
+