NAME
Test::DBUnit::Genertor - dbunit dataset generator
SYNOPSIS
use Test::DBUnit::Generator;
my $connection = DBIx::Connection->new(
name => 'test',
dsn => $ENV{DB_TEST_CONNECTION},
username => $ENV{DB_TEST_USERNAME},
password => $ENV{DB_TEST_PASSWORD},
);
my $generator = Test::DBUnit::Generator->new(
connection => $connection,
datasets => {
emp => 'SELECT * FROM emp',
dept => 'SELECT * FROM demp',
},
);
print $generator->xml;
print $generator->perl;
DESCRIPTION
This class generates xml or perl test datasets based on passed in sql
ATTRIBUTES
- connection
- datasets
METHODS
- xml
-
Returns xml content that contains dataset
- perl
- select_dataset
-
Returns dataset structure