NAME
Test::DBIC::SQLite - Connect and deploy a DBIx::Class::Schema on SQLite
SYNOPSIS
use Test::More;
use Test::DBIC::SQLite;
my $schema = connect_dbic_sqlite_ok('My::Schema');
done_testing();
DESCRIPTION
connect_dbic_sqlite_ok($class[, $dbname[, $callback]])
Create an SQLite database (default in memory) and deploy the schema.
Arguments
Positional.
- $class (Required)
-
The class name of the DBIx::Class::Schema to use.
- $dbname (Optional)
-
The default is :memory:, but a name for diskfile can be set here.
- $callback (Optional)
-
The callback is a codereference that is called after deploy and just before returning the schema instance. Usefull for populating the database.
Returns
An initialized instance of $class
.
LICENSE
(c) MMXV - Abe Timmerman <abeltje@cpan.org>
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.