tutorial/lib/MyApp/Model/DBIC.pm

filter: Statementstmt 100% 11 / 11 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 2 / 2 Podpod n/a totaltotal 100% 13 / 13 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
__ANON__
1.0
CRAP 1.0
« tutorial/lib/MyApp/Controller/API.pm ↑ Summary tutorial/lib/MyApp/Schema.pm »
1 #
2 # This file is part of CatalystX-ExtJS
3 #
4 # This software is Copyright (c) 2011 by Moritz Onken.
5 #
6 # This is free software, licensed under:
7 #
8 # The (three-clause) BSD License
9 #
10 package MyApp::Model::DBIC;
11 1 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
12 1 extends 'Catalyst::Model::DBIC::Schema';
13  
14 1 __PACKAGE__->config({
15 schema_class => 'MyApp::Schema',
16 connect_info => ['dbi:SQLite:dbname=:memory:']
17 });
18  
19 1 ▶ after BUILD => sub {
Subroutine __ANON__: called CC=1 SCAR=0.0
20 1 my $self = shift;
21 1 my $schema = $self->schema;
22 1 $schema->deploy;
23 1 $schema->resultset('User')->create({
24 email => 'onken@netcubed.de',
25 first => 'Moritz',
26 last => 'Onken'
27 });
28 1 };
29  
30 1 1;
« tutorial/lib/MyApp/Controller/API.pm ↑ Summary tutorial/lib/MyApp/Schema.pm »