automake_app/lib/App.pm untested

filter: Statementstmt 0.0% 0 / 10 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 2 Podpod 0.0% 0 / 1 totaltotal 0.0% 0 / 13 CC 1 SCAR 6.9
CC
1
Cov
0%
startup
2.0
BEGIN
2.0
CRAP 2.0
1 package <%= ${class} %>;
2 use Mojo::Base 'Mojolicious';
3  
4 # This method will run once at server start
5 sub startup {
6 my $self = shift;
7  
8 # Load configuration from hash returned by config file
9 my $config = $self->plugin('Config',
10 file => $self->home->rel_file('etc/<%= ${filename} %>.cfg')
11 );
12  
13 # Configure the application
14 $self->secrets($config->{secrets});
15  
16 # Router
17 my $r = $self->routes;
18  
19 # Normal route to controller
20 $r->get('/')->to('example#welcome');
21 }
22  
23 1;