Moxie

 view release on metacpan or  search on metacpan

t/050-non-mop-integration/003-attributes-in-non-mop-inherited-class.t  view on Meta::CPAN

6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
 
{
    package My::Component;
    BEGIN { $INC{'My/Component.pm'} = __FILE__ }
    use strict;
    use warnings;
 
    sub new {
        my $class = shift;
        bless { @_ } => $class;
    }
}
 
{
    package App;
    use Moxie
        traits => [':experimental'];
 
    extends 'https://metacpan.org/pod/Moxie::Object">Moxie::Object', 'My::Component';

t/050-non-mop-integration/003-attributes-in-non-mop-inherited-class.t  view on Meta::CPAN

52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
{
    package My::DBI;
    BEGIN { $INC{'My/DBI.pm'} = __FILE__ }
    use strict;
    use warnings;
 
    sub connect {
        my $class = shift;
        my ($dsn) = @_;
        bless { dsn => $dsn } => $class;
    }
 
    sub dsn { shift->{dsn} }
}
 
{
    package My::DBI::MOP;
    use Moxie
        traits => [':experimental'];



( run in 0.557 second using v1.01-cache-2.11-cpan-9b1e4054eb1 )