YMSG/NewFriendAlert.pm untested

filter: Statementstmt 0.0% 0 / 10 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 4 Podpod 0.0% 0 / 3 totaltotal 0.0% 0 / 17 CC 1 SCAR 6.9
CC
1
Cov
0%
from
2.0
to
2.0
to_string
2.0
CRAP 2.0
1 package Net::YMSG::NewFriendAlert;
2 use base 'Net::YMSG::Event';
3  
4  
5 sub from
6 {
7 my $self = shift;
8 $self->_get_by_name('PROPOSERS_ID');
9 }
10  
11  
12 sub to
13 {
14 my $self = shift;
15 $self->_get_by_name('NICKNAME');
16 }
17  
18  
19 sub to_string
20 {
21 my $self = shift;
22 sprintf "New Friend Alert: %s added %s as a Friend\nand also sent the following message:\n%s\n",
23 $self->from, $self->to, $self->body;
24 }
25  
26 1;
27 __END__