File Coverage

blib/lib/HTML/FormHandler/Field/Weekday.pm
Criterion Covered Total %
statement 10 10 100.0
branch n/a
condition n/a
subroutine 3 3 100.0
pod 0 1 0.0
total 13 14 92.8


line stmt bran cond sub pod time code
1             package HTML::FormHandler::Field::Weekday;
2             # ABSTRACT: select list day of week strings
3             $HTML::FormHandler::Field::Weekday::VERSION = '0.40068';
4 1     1   1051 use Moose;
  1         2  
  1         10  
5             extends 'HTML::FormHandler::Field::Select';
6              
7             sub build_options {
8 1     1 0 3 my $i = 0;
9 1         7 my @days = qw/
10             Sunday
11             Monday
12             Tuesday
13             Wednesday
14             Thursday
15             Friday
16             Saturday
17             /;
18 1         4 return [ map { { value => $i++, label => $_ } } @days ];
  7         47  
19             }
20              
21              
22             __PACKAGE__->meta->make_immutable;
23 1     1   7331 use namespace::autoclean;
  1         3  
  1         12  
24             1;
25              
26             __END__
27              
28             =pod
29              
30             =encoding UTF-8
31              
32             =head1 NAME
33              
34             HTML::FormHandler::Field::Weekday - select list day of week strings
35              
36             =head1 VERSION
37              
38             version 0.40068
39              
40             =head1 DESCRIPTION
41              
42             Creates an option list for the days of the week.
43              
44             =head1 AUTHOR
45              
46             FormHandler Contributors - see HTML::FormHandler
47              
48             =head1 COPYRIGHT AND LICENSE
49              
50             This software is copyright (c) 2017 by Gerda Shank.
51              
52             This is free software; you can redistribute it and/or modify it under
53             the same terms as the Perl 5 programming language system itself.
54              
55             =cut