AproJo/Command/author_tool.pm untested

filter: Statementstmt 0.0% 0 / 17 Branchbran n/a Conditioncond 0.0% 0 / 4 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 0.0% 0 / 4 Podpod 0.0% 0 / 2 totaltotal 0.0% 0 / 29 CC 1 SCAR 6.9
CC
1
Cov
0%
run
2.0
generate_install_scripts
2.0
BEGIN
2.0
CRAP 2.0
1 package AproJo::Command::author_tool;
2 use Mojo::Base 'Mojolicious::Command';
3  
4 use DBIx::Class::DeploymentHandler;
5  
6 sub run {
7 my $self = shift;
8  
9 my $command = shift || 'generate_install_scripts';
10 my $method = $self->can($command) or die "No command: $command\n";
11  
12 $self->$method();
13 }
14  
15 sub generate_install_scripts {
16 my $self = shift;
17  
18 my $schema = $self->app->schema;
19 my $dh = DBIx::Class::DeploymentHandler->new(
20 {
21 schema => $schema,
22 databases => [],
23 script_directory => 'lib/AproJo/files/sql',
24 }
25 );
26 my $version = $schema->schema_version;
27  
28 say "generating deployment script";
29 $dh->prepare_install;
30  
31 }
32  
33 1;