eval "use DBD::SQLite";
plan $@
? ( skip_all => 'needs DBD::SQLite for testing' )
- : ( tests => 8 );
+ : ( tests => 9 );
}
use_ok('DBICTest');
'got correct SQL for count query with quoting'
);
+# check that the table works
+eval {
+ my $rs = $schema->resultset('CDTableRef');
+ $rs->create({ cdid => 6, artist => 3, title => 'mtfnpy', year => 2009 });
+ my $row = $rs->find(6);
+ $row->update({ title => 'bleh' });
+ $row->delete;
+};
+ok !$@, 'operations on scalarref table name work';
+
my $order = 'year DESC';
$rs = $schema->resultset('CD')->search({},
{ 'order_by' => $order });