Jacquard/Actor/Role/Layoutable.pm untested

filter: Statementstmt 0.0% 0 / 14 Branchbran 0.0% 0 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 2 Podpod n/a totaltotal 0.0% 0 / 20 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1 use Renard::Incunabula::Common::Setup;
2 package Intertangle::Jacquard::Actor::Role::Layoutable;
3 # ABSTRACT: A role for actors that can layout their children
4 $Intertangle::Jacquard::Actor::Role::Layoutable::VERSION = '0.002';
5 use Moo::Role;
6  
7 with qw(Intertangle::Jacquard::Actor::Role::Tree::TreeDAGNode::WithChildren);
8  
9 has layout => (
10 is => 'ro',
11 predicate => 1,
12 );
13  
14 after add_child => method( $actor, %options ) {
15 if( $self->has_layout ) {
16 $self->layout->add_actor( $actor,
17 exists $options{layout} ? %{ $options{layout} } : ()
18 );
19 }
20 };
21  
22 1;
23  
24 __END__