blib/lib/Test/BDD/Cucumber/Model/Step.pm

filter: Statementstmt 100% 20 / 20 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 5 / 5 Podpod n/a totaltotal 100% 25 / 25 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« blib/lib/Test/BDD/Cucumber/Model/Feature.pm ↑ Summary examples/digest/features/step_definitions/basic_steps.pl »
1 27 ▶use v5.14;
Subroutine BEGIN: called CC=1 SCAR=0.0
2 27 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
3  
4 package Test::BDD::Cucumber::Model::Step 0.87;
5  
6 27 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 27 ▶use Types::Standard qw( Str ArrayRef InstanceOf );
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 =head1 NAME
10  
11 Test::BDD::Cucumber::Model::Step - Model to represent a step in a scenario
12  
13 =head1 VERSION
14  
15 version 0.87
16  
17 =head1 DESCRIPTION
18  
19 Model to represent a step in a scenario
20  
21 =head1 ATTRIBUTES
22  
23 =head2 text
24  
25 The text of the step, once Scenario Outlines have been applied
26  
27 =cut
28  
29 27 has 'text' => ( is => 'rw', isa => Str );
30  
31 =head2 verb
32  
33 =head2 verb_original
34  
35 The verb used for the step ('Given'/'When'/etc). C<verb_original> is the one
36 that appeared in the physical file - this will sometimes be C<and>.
37  
38 =cut
39  
40 27 has 'verb' => ( is => 'rw', isa => Str );
41 27 has 'verb_original' => ( is => 'rw', isa => Str );
42  
43 =head2 line
44  
45 The corresponding L<Test:BDD::Cucumber::Model::Line>
46  
47 =cut
48  
49 27 has 'line' => ( is => 'rw', isa => InstanceOf['Test::BDD::Cucumber::Model::Line'] );
50  
51 =head2 data
52  
53 Step-related data. Either a string in the case of C<"""> or an arrayref of
54 hashrefs for a data table.
55  
56 =cut
57  
58 27 has 'data' => ( is => 'rw' );
59  
60 =head2 data_as_strings
61  
62 An arrayref of strings containing the original step's data, for printing out
63 by harnesses
64  
65 =cut
66  
67 has 'data_as_strings' => (
68 is => 'rw',
69 677 ▶ default => sub { [] },
Subroutine __ANON__: called CC=1 SCAR=0.0
70 27 isa => ArrayRef[Str]
71 );
72  
73 =head2 columns
74  
75 If data was in a table format, then the column names will be here in the order
76 they appeared.
77  
78 =cut
79  
80 27 has 'columns' => ( is => 'rw', isa => ArrayRef[Str] );
81  
82 =head1 AUTHOR
83  
84 Peter Sergeant C<pete@clueball.com>
85  
86 =head1 LICENSE
87  
88 Copyright 2019-2023, Erik Huelsmann
89 Copyright 2011-2019, Peter Sergeant; Licensed under the same terms as Perl
90  
91 =cut
92  
93 27 1;
« blib/lib/Test/BDD/Cucumber/Model/Feature.pm ↑ Summary examples/digest/features/step_definitions/basic_steps.pl »