File Coverage

blib/lib/Acme/MJD/FR.pm
Criterion Covered Total %
statement 11 11 100.0
branch 2 2 100.0
condition 1 2 50.0
subroutine 3 3 100.0
pod 0 1 0.0
total 17 19 89.4


line stmt bran cond sub pod time code
1             package Acme::MJD::FR;
2              
3 1     1   20851 use strict;
  1         2  
  1         32  
4 1     1   4 use warnings;
  1         3  
  1         111  
5              
6             our $VERSION = '0.01';
7              
8             my @advice = ;
9              
10             sub advice {
11 2     2 0 558 my $number = shift;
12 2 100       6 if ($number) {
13 1         47 (my $advice) = grep /\Q$number/, @advice;
14 1   50     7 return $advice || '';
15             }
16             else {
17 1         54 return $advice[int rand @advice];
18             }
19             }
20              
21             1;
22              
23             =head1 NAME
24              
25             Acme::MJD::FR - the wisdom of Klortho the Magnificent, in French
26              
27             =head1 SYNOPSIS
28              
29             use Acme::MJD::Fr;
30             print Acme::MJD::Fr::advice;
31              
32             =head1 DESCRIPTION
33              
34             MJD's I,
35             translated in idiomatic French by Rafael Garcia-Suarez.
36              
37             =head1 LICENSE
38              
39             (c) Rafael Garcia-Suarez
40              
41             This program is free software; you may redistribute it and/or modify it under
42             the same terms as Perl itself.
43              
44             =head1 SEE ALSO
45              
46             L
47              
48             =cut
49              
50             __DATA__