File Coverage

blib/lib/Cucumber/Messages.pm
Criterion Covered Total %
statement 390 450 86.6
branch n/a
condition n/a
subroutine 130 190 68.4
pod n/a
total 520 640 81.2


line stmt bran cond sub pod time code
1             package Cucumber::Messages;
2             $Cucumber::Messages::VERSION = '34.0.1';
3             # DO NOT CHANGE THIS FILE!!
4              
5             # The code was auto-generated by this script:
6             # https://github.com/cucumber/messages/blob/main/codegen/codegen.rb
7              
8             =head1 NAME
9              
10             Cucumber::Messages - Library of classes to encapsulate Cucumber messages
11              
12             =head1 SYNOPSIS
13              
14             use Cucumber::Messages;
15              
16             my $loc = Cucumber::Messages::Location->new(
17             line => 12, column => 26
18             );
19             my $loc_json = $loc->to_json;
20              
21             my $envelope = Cucumber::Messages::Envelope->from_json($serialized_envelope);
22              
23             =head1 DESCRIPTION
24              
25             L
26             define the central protocol in the Cucumber ecosystem by which the various
27             components communicate. Messages are serialized to NDJSON.
28              
29             This library provides both serialization/deserialization to/from NDJSON as
30             well as the in-memory representation of the messages for Perl applications.
31              
32             Each serialized message should be wrapped in a C
33             and can thereby be deserialized by calling the C class message
34             with the serialized representation as its argument, like shown in the SYNOPSIS.
35              
36             =cut
37              
38 3     3   472033 use strict;
  3         5  
  3         106  
39 3     3   14 use warnings;
  3         7  
  3         155  
40              
41 3     3   994 use Cucumber::Messages::Message;
  3         9  
  3         153  
42              
43             =head1 MESSAGE CLASSES
44              
45             =cut
46              
47              
48              
49             package Cucumber::Messages::Attachment {
50             $Cucumber::Messages::Attachment::VERSION = '34.0.1';
51             =head2 Cucumber::Messages::Attachment
52              
53             =head3 DESCRIPTION
54              
55             Represents the Attachment message in Cucumber's
56             L.
57              
58             Attachments (parse errors, execution errors, screenshots, links...)
59              
60             An attachment represents any kind of data associated with a line in a
61             [Source](#io.cucumber.messages.Source) file. It can be used for:
62              
63             * Syntax errors during parse time
64             * Screenshots captured and attached during execution
65             * Logs captured and attached during execution
66              
67             It is not to be used for runtime errors raised/thrown during execution. This
68             is captured in `TestResult`.
69              
70             =head3 ATTRIBUTES
71              
72             =cut
73              
74 3     3   17 use Moo;
  3         3  
  3         13  
75             extends 'Cucumber::Messages::Message';
76              
77 3     3   836 use Scalar::Util qw( blessed );
  3         3  
  3         386  
78              
79             my %types = (
80             body => 'string',
81             content_encoding => '',
82             file_name => 'string',
83             media_type => 'string',
84             source => 'Cucumber::Messages::Source',
85             test_case_started_id => 'string',
86             test_step_id => 'string',
87             url => 'string',
88             test_run_started_id => 'string',
89             test_run_hook_started_id => 'string',
90             timestamp => 'Cucumber::Messages::Timestamp',
91             );
92              
93             # This is a work-around for the fact that Moo doesn't have introspection
94             # and Perl doesn't have boolean values...
95             sub _types {
96 0     0     return \%types;
97             }
98              
99              
100              
101             =head4 body
102              
103             The body of the attachment. If `contentEncoding` is `IDENTITY`, the attachment
104             is simply the string. If it's `BASE64`, the string should be Base64 decoded to
105             obtain the attachment.
106             =cut
107              
108             has body =>
109             (is => 'ro',
110             required => 1,
111             default => sub { '' },
112             );
113              
114              
115             =head4 content_encoding
116              
117             Whether to interpret `body` "as-is" (IDENTITY) or if it needs to be Base64-decoded (BASE64).
118              
119             Content encoding is *not* determined by the media type, but rather by the type
120             of the object being attached:
121              
122             - string: IDENTITY
123             - byte array: BASE64
124             - stream: BASE64
125              
126             Available constants for valid values of this field:
127              
128             =over
129              
130             =item * CONTENTENCODING_IDENTITY
131              
132             =item * CONTENTENCODING_BASE64
133              
134             =back
135              
136             =cut
137              
138              
139             use constant {
140 3         628 CONTENTENCODING_IDENTITY => 'IDENTITY',
141             CONTENTENCODING_BASE64 => 'BASE64',
142 3     3   18 };
  3         4  
143              
144             has content_encoding =>
145             (is => 'ro',
146             required => 1,
147             default => sub { CONTENTENCODING_IDENTITY },
148             );
149              
150              
151             =head4 file_name
152              
153             Suggested file name of the attachment. (Provided by the user as an argument to `attach`)
154             =cut
155              
156             has file_name =>
157             (is => 'ro',
158             );
159              
160              
161             =head4 media_type
162              
163             The media type of the data. This can be any valid
164             [IANA Media Type](https://www.iana.org/assignments/media-types/media-types.xhtml)
165             as well as Cucumber-specific media types such as `text/x.cucumber.gherkin+plain`
166             and `text/x.cucumber.stacktrace+plain`
167             =cut
168              
169             has media_type =>
170             (is => 'ro',
171             required => 1,
172             default => sub { '' },
173             );
174              
175              
176             =head4 source
177              
178              
179             =cut
180              
181             has source =>
182             (is => 'ro',
183             );
184              
185              
186             =head4 test_case_started_id
187              
188             The identifier of the test case attempt if the attachment was created during the execution of a test step
189             =cut
190              
191             has test_case_started_id =>
192             (is => 'ro',
193             );
194              
195              
196             =head4 test_step_id
197              
198             The identifier of the test step if the attachment was created during the execution of a test step
199             =cut
200              
201             has test_step_id =>
202             (is => 'ro',
203             );
204              
205              
206             =head4 url
207              
208             A URL where the attachment can be retrieved. This field should not be set by Cucumber.
209             It should be set by a program that reads a message stream and does the following for
210             each Attachment message:
211              
212             - Writes the body (after base64 decoding if necessary) to a new file.
213             - Sets `body` and `contentEncoding` to `null`
214             - Writes out the new attachment message
215              
216             This will result in a smaller message stream, which can improve performance and
217             reduce bandwidth of message consumers. It also makes it easier to process and download attachments
218             separately from reports.
219              
220             Deprecated; use ExternalAttachment instead.
221             =cut
222              
223             has url =>
224             (is => 'ro',
225             );
226              
227              
228             =head4 test_run_started_id
229              
230             Not used; implementers should instead populate `testRunHookStartedId` if an attachment was created during the execution of a test run hook
231             =cut
232              
233             has test_run_started_id =>
234             (is => 'ro',
235             );
236              
237              
238             =head4 test_run_hook_started_id
239              
240             The identifier of the test run hook execution if the attachment was created during the execution of a test run hook
241             =cut
242              
243             has test_run_hook_started_id =>
244             (is => 'ro',
245             );
246              
247              
248             =head4 timestamp
249              
250             When the attachment was created
251             =cut
252              
253             has timestamp =>
254             (is => 'ro',
255             );
256              
257              
258             }
259              
260             package Cucumber::Messages::Duration {
261             $Cucumber::Messages::Duration::VERSION = '34.0.1';
262             =head2 Cucumber::Messages::Duration
263              
264             =head3 DESCRIPTION
265              
266             Represents the Duration message in Cucumber's
267             L.
268              
269             The structure is pretty close of the Timestamp one. For clarity, a second type
270             of message is used.
271              
272             =head3 ATTRIBUTES
273              
274             =cut
275              
276 3     3   17 use Moo;
  3         21  
  3         11  
277             extends 'Cucumber::Messages::Message';
278              
279 3     3   832 use Scalar::Util qw( blessed );
  3         13  
  3         451  
280              
281             my %types = (
282             seconds => 'number',
283             nanos => 'number',
284             );
285              
286             # This is a work-around for the fact that Moo doesn't have introspection
287             # and Perl doesn't have boolean values...
288             sub _types {
289 0     0     return \%types;
290             }
291              
292              
293              
294             =head4 seconds
295              
296              
297             =cut
298              
299             has seconds =>
300             (is => 'ro',
301             required => 1,
302             default => sub { 0 },
303             );
304              
305              
306             =head4 nanos
307              
308             Non-negative fractions of a second at nanosecond resolution. Negative
309             second values with fractions must still have non-negative nanos values
310             that count forward in time. Must be from 0 to 999,999,999
311             inclusive.
312             =cut
313              
314             has nanos =>
315             (is => 'ro',
316             required => 1,
317             default => sub { 0 },
318             );
319              
320              
321             }
322              
323             package Cucumber::Messages::Envelope {
324             $Cucumber::Messages::Envelope::VERSION = '34.0.1';
325             =head2 Cucumber::Messages::Envelope
326              
327             =head3 DESCRIPTION
328              
329             Represents the Envelope message in Cucumber's
330             L.
331              
332              
333              
334             =head3 ATTRIBUTES
335              
336             =cut
337              
338 3     3   13 use Moo;
  3         13  
  3         10  
339             extends 'Cucumber::Messages::Message';
340              
341 3     3   827 use Scalar::Util qw( blessed );
  3         6  
  3         906  
342              
343             my %types = (
344             attachment => 'Cucumber::Messages::Attachment',
345             external_attachment => 'Cucumber::Messages::ExternalAttachment',
346             gherkin_document => 'Cucumber::Messages::GherkinDocument',
347             hook => 'Cucumber::Messages::Hook',
348             meta => 'Cucumber::Messages::Meta',
349             parameter_type => 'Cucumber::Messages::ParameterType',
350             parse_error => 'Cucumber::Messages::ParseError',
351             pickle => 'Cucumber::Messages::Pickle',
352             suggestion => 'Cucumber::Messages::Suggestion',
353             source => 'Cucumber::Messages::Source',
354             step_definition => 'Cucumber::Messages::StepDefinition',
355             test_case => 'Cucumber::Messages::TestCase',
356             test_case_finished => 'Cucumber::Messages::TestCaseFinished',
357             test_case_started => 'Cucumber::Messages::TestCaseStarted',
358             test_run_finished => 'Cucumber::Messages::TestRunFinished',
359             test_run_started => 'Cucumber::Messages::TestRunStarted',
360             test_step_finished => 'Cucumber::Messages::TestStepFinished',
361             test_step_started => 'Cucumber::Messages::TestStepStarted',
362             test_run_hook_started => 'Cucumber::Messages::TestRunHookStarted',
363             test_run_hook_finished => 'Cucumber::Messages::TestRunHookFinished',
364             undefined_parameter_type => 'Cucumber::Messages::UndefinedParameterType',
365             );
366              
367             # This is a work-around for the fact that Moo doesn't have introspection
368             # and Perl doesn't have boolean values...
369             sub _types {
370 0     0     return \%types;
371             }
372              
373              
374              
375             =head4 attachment
376              
377              
378             =cut
379              
380             has attachment =>
381             (is => 'ro',
382             );
383              
384              
385             =head4 external_attachment
386              
387              
388             =cut
389              
390             has external_attachment =>
391             (is => 'ro',
392             );
393              
394              
395             =head4 gherkin_document
396              
397              
398             =cut
399              
400             has gherkin_document =>
401             (is => 'ro',
402             );
403              
404              
405             =head4 hook
406              
407              
408             =cut
409              
410             has hook =>
411             (is => 'ro',
412             );
413              
414              
415             =head4 meta
416              
417              
418             =cut
419              
420             has meta =>
421             (is => 'ro',
422             );
423              
424              
425             =head4 parameter_type
426              
427              
428             =cut
429              
430             has parameter_type =>
431             (is => 'ro',
432             );
433              
434              
435             =head4 parse_error
436              
437              
438             =cut
439              
440             has parse_error =>
441             (is => 'ro',
442             );
443              
444              
445             =head4 pickle
446              
447              
448             =cut
449              
450             has pickle =>
451             (is => 'ro',
452             );
453              
454              
455             =head4 suggestion
456              
457              
458             =cut
459              
460             has suggestion =>
461             (is => 'ro',
462             );
463              
464              
465             =head4 source
466              
467              
468             =cut
469              
470             has source =>
471             (is => 'ro',
472             );
473              
474              
475             =head4 step_definition
476              
477              
478             =cut
479              
480             has step_definition =>
481             (is => 'ro',
482             );
483              
484              
485             =head4 test_case
486              
487              
488             =cut
489              
490             has test_case =>
491             (is => 'ro',
492             );
493              
494              
495             =head4 test_case_finished
496              
497              
498             =cut
499              
500             has test_case_finished =>
501             (is => 'ro',
502             );
503              
504              
505             =head4 test_case_started
506              
507              
508             =cut
509              
510             has test_case_started =>
511             (is => 'ro',
512             );
513              
514              
515             =head4 test_run_finished
516              
517              
518             =cut
519              
520             has test_run_finished =>
521             (is => 'ro',
522             );
523              
524              
525             =head4 test_run_started
526              
527              
528             =cut
529              
530             has test_run_started =>
531             (is => 'ro',
532             );
533              
534              
535             =head4 test_step_finished
536              
537              
538             =cut
539              
540             has test_step_finished =>
541             (is => 'ro',
542             );
543              
544              
545             =head4 test_step_started
546              
547              
548             =cut
549              
550             has test_step_started =>
551             (is => 'ro',
552             );
553              
554              
555             =head4 test_run_hook_started
556              
557              
558             =cut
559              
560             has test_run_hook_started =>
561             (is => 'ro',
562             );
563              
564              
565             =head4 test_run_hook_finished
566              
567              
568             =cut
569              
570             has test_run_hook_finished =>
571             (is => 'ro',
572             );
573              
574              
575             =head4 undefined_parameter_type
576              
577              
578             =cut
579              
580             has undefined_parameter_type =>
581             (is => 'ro',
582             );
583              
584              
585             }
586              
587             package Cucumber::Messages::Exception {
588             $Cucumber::Messages::Exception::VERSION = '34.0.1';
589             =head2 Cucumber::Messages::Exception
590              
591             =head3 DESCRIPTION
592              
593             Represents the Exception message in Cucumber's
594             L.
595              
596             A simplified representation of an exception
597              
598             =head3 ATTRIBUTES
599              
600             =cut
601              
602 3     3   17 use Moo;
  3         3  
  3         12  
603             extends 'Cucumber::Messages::Message';
604              
605 3     3   854 use Scalar::Util qw( blessed );
  3         4  
  3         370  
606              
607             my %types = (
608             type => 'string',
609             message => 'string',
610             stack_trace => 'string',
611             );
612              
613             # This is a work-around for the fact that Moo doesn't have introspection
614             # and Perl doesn't have boolean values...
615             sub _types {
616 0     0     return \%types;
617             }
618              
619              
620              
621             =head4 type
622              
623             The type of the exception that caused this result. E.g. "Error" or "org.opentest4j.AssertionFailedError"
624             =cut
625              
626             has type =>
627             (is => 'ro',
628             required => 1,
629             default => sub { '' },
630             );
631              
632              
633             =head4 message
634              
635             The message of exception that caused this result. E.g. expected: "a" but was: "b"
636             =cut
637              
638             has message =>
639             (is => 'ro',
640             );
641              
642              
643             =head4 stack_trace
644              
645             The stringified stack trace of the exception that caused this result
646             =cut
647              
648             has stack_trace =>
649             (is => 'ro',
650             );
651              
652              
653             }
654              
655             package Cucumber::Messages::ExternalAttachment {
656             $Cucumber::Messages::ExternalAttachment::VERSION = '34.0.1';
657             =head2 Cucumber::Messages::ExternalAttachment
658              
659             =head3 DESCRIPTION
660              
661             Represents the ExternalAttachment message in Cucumber's
662             L.
663              
664             Represents an attachment that is stored externally rather than embedded in the message stream.
665              
666             This message type is used for large attachments (e.g., video files) that are already
667             on the filesystem and should not be loaded into memory. Instead of embedding the content,
668             only a URL reference is stored.
669              
670             A formatter or other consumer of messages may replace an Attachment with an ExternalAttachment if it makes sense to do so.
671              
672             =head3 ATTRIBUTES
673              
674             =cut
675              
676 3     3   12 use Moo;
  3         5  
  3         7  
677             extends 'Cucumber::Messages::Message';
678              
679 3     3   846 use Scalar::Util qw( blessed );
  3         5  
  3         506  
680              
681             my %types = (
682             url => 'string',
683             media_type => 'string',
684             test_case_started_id => 'string',
685             test_step_id => 'string',
686             test_run_hook_started_id => 'string',
687             timestamp => 'Cucumber::Messages::Timestamp',
688             );
689              
690             # This is a work-around for the fact that Moo doesn't have introspection
691             # and Perl doesn't have boolean values...
692             sub _types {
693 0     0     return \%types;
694             }
695              
696              
697              
698             =head4 url
699              
700             A URL where the attachment can be retrieved. This could be a file:// URL for
701             local filesystem paths, or an http(s):// URL for remote resources.
702             =cut
703              
704             has url =>
705             (is => 'ro',
706             required => 1,
707             default => sub { '' },
708             );
709              
710              
711             =head4 media_type
712              
713             The media type of the data. This can be any valid
714             [IANA Media Type](https://www.iana.org/assignments/media-types/media-types.xhtml)
715             as well as Cucumber-specific media types such as `text/x.cucumber.gherkin+plain`
716             and `text/x.cucumber.stacktrace+plain`
717             =cut
718              
719             has media_type =>
720             (is => 'ro',
721             required => 1,
722             default => sub { '' },
723             );
724              
725              
726             =head4 test_case_started_id
727              
728             The identifier of the test case attempt if the attachment was created during the execution of a test step
729             =cut
730              
731             has test_case_started_id =>
732             (is => 'ro',
733             );
734              
735              
736             =head4 test_step_id
737              
738             The identifier of the test step if the attachment was created during the execution of a test step
739             =cut
740              
741             has test_step_id =>
742             (is => 'ro',
743             );
744              
745              
746             =head4 test_run_hook_started_id
747              
748             The identifier of the test run hook execution if the attachment was created during the execution of a test run hook
749             =cut
750              
751             has test_run_hook_started_id =>
752             (is => 'ro',
753             );
754              
755              
756             =head4 timestamp
757              
758             When the attachment was created
759             =cut
760              
761             has timestamp =>
762             (is => 'ro',
763             );
764              
765              
766             }
767              
768             package Cucumber::Messages::GherkinDocument {
769             $Cucumber::Messages::GherkinDocument::VERSION = '34.0.1';
770             =head2 Cucumber::Messages::GherkinDocument
771              
772             =head3 DESCRIPTION
773              
774             Represents the GherkinDocument message in Cucumber's
775             L.
776              
777             The [AST](https://en.wikipedia.org/wiki/Abstract_syntax_tree) of a Gherkin document.
778             Cucumber implementations should *not* depend on `GherkinDocument` or any of its
779             children for execution - use [Pickle](#io.cucumber.messages.Pickle) instead.
780              
781             The only consumers of `GherkinDocument` should only be formatters that produce
782             "rich" output, resembling the original Gherkin document.
783              
784             =head3 ATTRIBUTES
785              
786             =cut
787              
788 3     3   14 use Moo;
  3         4  
  3         14  
789             extends 'Cucumber::Messages::Message';
790              
791 3     3   980 use Scalar::Util qw( blessed );
  3         5  
  3         573  
792              
793             my %types = (
794             uri => 'string',
795             feature => 'Cucumber::Messages::Feature',
796             comments => '[]Cucumber::Messages::Comment',
797             );
798              
799             # This is a work-around for the fact that Moo doesn't have introspection
800             # and Perl doesn't have boolean values...
801             sub _types {
802 0     0     return \%types;
803             }
804              
805              
806              
807             =head4 uri
808              
809             The [URI](https://en.wikipedia.org/wiki/Uniform_Resource_Identifier)
810             of the source, typically a file path relative to the root directory
811             =cut
812              
813             has uri =>
814             (is => 'ro',
815             );
816              
817              
818             =head4 feature
819              
820              
821             =cut
822              
823             has feature =>
824             (is => 'ro',
825             );
826              
827              
828             =head4 comments
829              
830             All the comments in the Gherkin document
831             =cut
832              
833             has comments =>
834             (is => 'ro',
835             required => 1,
836             default => sub { [] },
837             );
838              
839              
840             }
841              
842             package Cucumber::Messages::Background {
843             $Cucumber::Messages::Background::VERSION = '34.0.1';
844             =head2 Cucumber::Messages::Background
845              
846             =head3 DESCRIPTION
847              
848             Represents the Background message in Cucumber's
849             L.
850              
851              
852              
853             =head3 ATTRIBUTES
854              
855             =cut
856              
857 3     3   16 use Moo;
  3         4  
  3         14  
858             extends 'Cucumber::Messages::Message';
859              
860 3     3   856 use Scalar::Util qw( blessed );
  3         4  
  3         740  
861              
862             my %types = (
863             location => 'Cucumber::Messages::Location',
864             keyword => 'string',
865             name => 'string',
866             description => 'string',
867             steps => '[]Cucumber::Messages::Step',
868             id => 'string',
869             );
870              
871             # This is a work-around for the fact that Moo doesn't have introspection
872             # and Perl doesn't have boolean values...
873             sub _types {
874 0     0     return \%types;
875             }
876              
877              
878              
879             =head4 location
880              
881             The location of the `Background` keyword
882             =cut
883              
884             has location =>
885             (is => 'ro',
886             required => 1,
887             default => sub { Cucumber::Messages::Location->new() },
888             );
889              
890              
891             =head4 keyword
892              
893              
894             =cut
895              
896             has keyword =>
897             (is => 'ro',
898             required => 1,
899             default => sub { '' },
900             );
901              
902              
903             =head4 name
904              
905              
906             =cut
907              
908             has name =>
909             (is => 'ro',
910             required => 1,
911             default => sub { '' },
912             );
913              
914              
915             =head4 description
916              
917              
918             =cut
919              
920             has description =>
921             (is => 'ro',
922             required => 1,
923             default => sub { '' },
924             );
925              
926              
927             =head4 steps
928              
929              
930             =cut
931              
932             has steps =>
933             (is => 'ro',
934             required => 1,
935             default => sub { [] },
936             );
937              
938              
939             =head4 id
940              
941              
942             =cut
943              
944             has id =>
945             (is => 'ro',
946             required => 1,
947             default => sub { '' },
948             );
949              
950              
951             }
952              
953             package Cucumber::Messages::Comment {
954             $Cucumber::Messages::Comment::VERSION = '34.0.1';
955             =head2 Cucumber::Messages::Comment
956              
957             =head3 DESCRIPTION
958              
959             Represents the Comment message in Cucumber's
960             L.
961              
962             A comment in a Gherkin document
963              
964             =head3 ATTRIBUTES
965              
966             =cut
967              
968 3     3   17 use Moo;
  3         5  
  3         13  
969             extends 'Cucumber::Messages::Message';
970              
971 3     3   921 use Scalar::Util qw( blessed );
  3         12  
  3         493  
972              
973             my %types = (
974             location => 'Cucumber::Messages::Location',
975             text => 'string',
976             );
977              
978             # This is a work-around for the fact that Moo doesn't have introspection
979             # and Perl doesn't have boolean values...
980             sub _types {
981 0     0     return \%types;
982             }
983              
984              
985              
986             =head4 location
987              
988             The location of the comment
989             =cut
990              
991             has location =>
992             (is => 'ro',
993             required => 1,
994             default => sub { Cucumber::Messages::Location->new() },
995             );
996              
997              
998             =head4 text
999              
1000             The text of the comment
1001             =cut
1002              
1003             has text =>
1004             (is => 'ro',
1005             required => 1,
1006             default => sub { '' },
1007             );
1008              
1009              
1010             }
1011              
1012             package Cucumber::Messages::DataTable {
1013             $Cucumber::Messages::DataTable::VERSION = '34.0.1';
1014             =head2 Cucumber::Messages::DataTable
1015              
1016             =head3 DESCRIPTION
1017              
1018             Represents the DataTable message in Cucumber's
1019             L.
1020              
1021              
1022              
1023             =head3 ATTRIBUTES
1024              
1025             =cut
1026              
1027 3     3   18 use Moo;
  3         6  
  3         11  
1028             extends 'Cucumber::Messages::Message';
1029              
1030 3     3   972 use Scalar::Util qw( blessed );
  3         19  
  3         509  
1031              
1032             my %types = (
1033             location => 'Cucumber::Messages::Location',
1034             rows => '[]Cucumber::Messages::TableRow',
1035             );
1036              
1037             # This is a work-around for the fact that Moo doesn't have introspection
1038             # and Perl doesn't have boolean values...
1039             sub _types {
1040 0     0     return \%types;
1041             }
1042              
1043              
1044              
1045             =head4 location
1046              
1047              
1048             =cut
1049              
1050             has location =>
1051             (is => 'ro',
1052             required => 1,
1053             default => sub { Cucumber::Messages::Location->new() },
1054             );
1055              
1056              
1057             =head4 rows
1058              
1059              
1060             =cut
1061              
1062             has rows =>
1063             (is => 'ro',
1064             required => 1,
1065             default => sub { [] },
1066             );
1067              
1068              
1069             }
1070              
1071             package Cucumber::Messages::DocString {
1072             $Cucumber::Messages::DocString::VERSION = '34.0.1';
1073             =head2 Cucumber::Messages::DocString
1074              
1075             =head3 DESCRIPTION
1076              
1077             Represents the DocString message in Cucumber's
1078             L.
1079              
1080              
1081              
1082             =head3 ATTRIBUTES
1083              
1084             =cut
1085              
1086 3     3   17 use Moo;
  3         4  
  3         14  
1087             extends 'Cucumber::Messages::Message';
1088              
1089 3     3   1331 use Scalar::Util qw( blessed );
  3         23  
  3         712  
1090              
1091             my %types = (
1092             location => 'Cucumber::Messages::Location',
1093             media_type => 'string',
1094             content => 'string',
1095             delimiter => 'string',
1096             );
1097              
1098             # This is a work-around for the fact that Moo doesn't have introspection
1099             # and Perl doesn't have boolean values...
1100             sub _types {
1101 0     0     return \%types;
1102             }
1103              
1104              
1105              
1106             =head4 location
1107              
1108              
1109             =cut
1110              
1111             has location =>
1112             (is => 'ro',
1113             required => 1,
1114             default => sub { Cucumber::Messages::Location->new() },
1115             );
1116              
1117              
1118             =head4 media_type
1119              
1120              
1121             =cut
1122              
1123             has media_type =>
1124             (is => 'ro',
1125             );
1126              
1127              
1128             =head4 content
1129              
1130              
1131             =cut
1132              
1133             has content =>
1134             (is => 'ro',
1135             required => 1,
1136             default => sub { '' },
1137             );
1138              
1139              
1140             =head4 delimiter
1141              
1142              
1143             =cut
1144              
1145             has delimiter =>
1146             (is => 'ro',
1147             required => 1,
1148             default => sub { '' },
1149             );
1150              
1151              
1152             }
1153              
1154             package Cucumber::Messages::Examples {
1155             $Cucumber::Messages::Examples::VERSION = '34.0.1';
1156             =head2 Cucumber::Messages::Examples
1157              
1158             =head3 DESCRIPTION
1159              
1160             Represents the Examples message in Cucumber's
1161             L.
1162              
1163              
1164              
1165             =head3 ATTRIBUTES
1166              
1167             =cut
1168              
1169 3     3   28 use Moo;
  3         6  
  3         12  
1170             extends 'Cucumber::Messages::Message';
1171              
1172 3     3   1304 use Scalar::Util qw( blessed );
  3         6  
  3         883  
1173              
1174             my %types = (
1175             location => 'Cucumber::Messages::Location',
1176             tags => '[]Cucumber::Messages::Tag',
1177             keyword => 'string',
1178             name => 'string',
1179             description => 'string',
1180             table_header => 'Cucumber::Messages::TableRow',
1181             table_body => '[]Cucumber::Messages::TableRow',
1182             id => 'string',
1183             );
1184              
1185             # This is a work-around for the fact that Moo doesn't have introspection
1186             # and Perl doesn't have boolean values...
1187             sub _types {
1188 0     0     return \%types;
1189             }
1190              
1191              
1192              
1193             =head4 location
1194              
1195             The location of the `Examples` keyword
1196             =cut
1197              
1198             has location =>
1199             (is => 'ro',
1200             required => 1,
1201             default => sub { Cucumber::Messages::Location->new() },
1202             );
1203              
1204              
1205             =head4 tags
1206              
1207              
1208             =cut
1209              
1210             has tags =>
1211             (is => 'ro',
1212             required => 1,
1213             default => sub { [] },
1214             );
1215              
1216              
1217             =head4 keyword
1218              
1219              
1220             =cut
1221              
1222             has keyword =>
1223             (is => 'ro',
1224             required => 1,
1225             default => sub { '' },
1226             );
1227              
1228              
1229             =head4 name
1230              
1231              
1232             =cut
1233              
1234             has name =>
1235             (is => 'ro',
1236             required => 1,
1237             default => sub { '' },
1238             );
1239              
1240              
1241             =head4 description
1242              
1243              
1244             =cut
1245              
1246             has description =>
1247             (is => 'ro',
1248             required => 1,
1249             default => sub { '' },
1250             );
1251              
1252              
1253             =head4 table_header
1254              
1255              
1256             =cut
1257              
1258             has table_header =>
1259             (is => 'ro',
1260             );
1261              
1262              
1263             =head4 table_body
1264              
1265              
1266             =cut
1267              
1268             has table_body =>
1269             (is => 'ro',
1270             required => 1,
1271             default => sub { [] },
1272             );
1273              
1274              
1275             =head4 id
1276              
1277              
1278             =cut
1279              
1280             has id =>
1281             (is => 'ro',
1282             required => 1,
1283             default => sub { '' },
1284             );
1285              
1286              
1287             }
1288              
1289             package Cucumber::Messages::Feature {
1290             $Cucumber::Messages::Feature::VERSION = '34.0.1';
1291             =head2 Cucumber::Messages::Feature
1292              
1293             =head3 DESCRIPTION
1294              
1295             Represents the Feature message in Cucumber's
1296             L.
1297              
1298              
1299              
1300             =head3 ATTRIBUTES
1301              
1302             =cut
1303              
1304 3     3   21 use Moo;
  3         7  
  3         13  
1305             extends 'Cucumber::Messages::Message';
1306              
1307 3     3   1208 use Scalar::Util qw( blessed );
  3         6  
  3         1006  
1308              
1309             my %types = (
1310             location => 'Cucumber::Messages::Location',
1311             tags => '[]Cucumber::Messages::Tag',
1312             language => 'string',
1313             keyword => 'string',
1314             name => 'string',
1315             description => 'string',
1316             children => '[]Cucumber::Messages::FeatureChild',
1317             );
1318              
1319             # This is a work-around for the fact that Moo doesn't have introspection
1320             # and Perl doesn't have boolean values...
1321             sub _types {
1322 0     0     return \%types;
1323             }
1324              
1325              
1326              
1327             =head4 location
1328              
1329             The location of the `Feature` keyword
1330             =cut
1331              
1332             has location =>
1333             (is => 'ro',
1334             required => 1,
1335             default => sub { Cucumber::Messages::Location->new() },
1336             );
1337              
1338              
1339             =head4 tags
1340              
1341             All the tags placed above the `Feature` keyword
1342             =cut
1343              
1344             has tags =>
1345             (is => 'ro',
1346             required => 1,
1347             default => sub { [] },
1348             );
1349              
1350              
1351             =head4 language
1352              
1353             The [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1) language code of the Gherkin document
1354             =cut
1355              
1356             has language =>
1357             (is => 'ro',
1358             required => 1,
1359             default => sub { '' },
1360             );
1361              
1362              
1363             =head4 keyword
1364              
1365             The text of the `Feature` keyword (in the language specified by `language`)
1366             =cut
1367              
1368             has keyword =>
1369             (is => 'ro',
1370             required => 1,
1371             default => sub { '' },
1372             );
1373              
1374              
1375             =head4 name
1376              
1377             The name of the feature (the text following the `keyword`)
1378             =cut
1379              
1380             has name =>
1381             (is => 'ro',
1382             required => 1,
1383             default => sub { '' },
1384             );
1385              
1386              
1387             =head4 description
1388              
1389             The line(s) underneath the line with the `keyword` that are used as description
1390             =cut
1391              
1392             has description =>
1393             (is => 'ro',
1394             required => 1,
1395             default => sub { '' },
1396             );
1397              
1398              
1399             =head4 children
1400              
1401             Zero or more children
1402             =cut
1403              
1404             has children =>
1405             (is => 'ro',
1406             required => 1,
1407             default => sub { [] },
1408             );
1409              
1410              
1411             }
1412              
1413             package Cucumber::Messages::FeatureChild {
1414             $Cucumber::Messages::FeatureChild::VERSION = '34.0.1';
1415             =head2 Cucumber::Messages::FeatureChild
1416              
1417             =head3 DESCRIPTION
1418              
1419             Represents the FeatureChild message in Cucumber's
1420             L.
1421              
1422             A child node of a `Feature` node
1423              
1424             =head3 ATTRIBUTES
1425              
1426             =cut
1427              
1428 3     3   21 use Moo;
  3         5  
  3         13  
1429             extends 'Cucumber::Messages::Message';
1430              
1431 3     3   1133 use Scalar::Util qw( blessed );
  3         4  
  3         535  
1432              
1433             my %types = (
1434             rule => 'Cucumber::Messages::Rule',
1435             background => 'Cucumber::Messages::Background',
1436             scenario => 'Cucumber::Messages::Scenario',
1437             );
1438              
1439             # This is a work-around for the fact that Moo doesn't have introspection
1440             # and Perl doesn't have boolean values...
1441             sub _types {
1442 0     0     return \%types;
1443             }
1444              
1445              
1446              
1447             =head4 rule
1448              
1449              
1450             =cut
1451              
1452             has rule =>
1453             (is => 'ro',
1454             );
1455              
1456              
1457             =head4 background
1458              
1459              
1460             =cut
1461              
1462             has background =>
1463             (is => 'ro',
1464             );
1465              
1466              
1467             =head4 scenario
1468              
1469              
1470             =cut
1471              
1472             has scenario =>
1473             (is => 'ro',
1474             );
1475              
1476              
1477             }
1478              
1479             package Cucumber::Messages::Rule {
1480             $Cucumber::Messages::Rule::VERSION = '34.0.1';
1481             =head2 Cucumber::Messages::Rule
1482              
1483             =head3 DESCRIPTION
1484              
1485             Represents the Rule message in Cucumber's
1486             L.
1487              
1488              
1489              
1490             =head3 ATTRIBUTES
1491              
1492             =cut
1493              
1494 3     3   17 use Moo;
  3         5  
  3         24  
1495             extends 'Cucumber::Messages::Message';
1496              
1497 3     3   963 use Scalar::Util qw( blessed );
  3         6  
  3         845  
1498              
1499             my %types = (
1500             location => 'Cucumber::Messages::Location',
1501             tags => '[]Cucumber::Messages::Tag',
1502             keyword => 'string',
1503             name => 'string',
1504             description => 'string',
1505             children => '[]Cucumber::Messages::RuleChild',
1506             id => 'string',
1507             );
1508              
1509             # This is a work-around for the fact that Moo doesn't have introspection
1510             # and Perl doesn't have boolean values...
1511             sub _types {
1512 0     0     return \%types;
1513             }
1514              
1515              
1516              
1517             =head4 location
1518              
1519             The location of the `Rule` keyword
1520             =cut
1521              
1522             has location =>
1523             (is => 'ro',
1524             required => 1,
1525             default => sub { Cucumber::Messages::Location->new() },
1526             );
1527              
1528              
1529             =head4 tags
1530              
1531             All the tags placed above the `Rule` keyword
1532             =cut
1533              
1534             has tags =>
1535             (is => 'ro',
1536             required => 1,
1537             default => sub { [] },
1538             );
1539              
1540              
1541             =head4 keyword
1542              
1543              
1544             =cut
1545              
1546             has keyword =>
1547             (is => 'ro',
1548             required => 1,
1549             default => sub { '' },
1550             );
1551              
1552              
1553             =head4 name
1554              
1555              
1556             =cut
1557              
1558             has name =>
1559             (is => 'ro',
1560             required => 1,
1561             default => sub { '' },
1562             );
1563              
1564              
1565             =head4 description
1566              
1567              
1568             =cut
1569              
1570             has description =>
1571             (is => 'ro',
1572             required => 1,
1573             default => sub { '' },
1574             );
1575              
1576              
1577             =head4 children
1578              
1579              
1580             =cut
1581              
1582             has children =>
1583             (is => 'ro',
1584             required => 1,
1585             default => sub { [] },
1586             );
1587              
1588              
1589             =head4 id
1590              
1591              
1592             =cut
1593              
1594             has id =>
1595             (is => 'ro',
1596             required => 1,
1597             default => sub { '' },
1598             );
1599              
1600              
1601             }
1602              
1603             package Cucumber::Messages::RuleChild {
1604             $Cucumber::Messages::RuleChild::VERSION = '34.0.1';
1605             =head2 Cucumber::Messages::RuleChild
1606              
1607             =head3 DESCRIPTION
1608              
1609             Represents the RuleChild message in Cucumber's
1610             L.
1611              
1612             A child node of a `Rule` node
1613              
1614             =head3 ATTRIBUTES
1615              
1616             =cut
1617              
1618 3     3   21 use Moo;
  3         6  
  3         62  
1619             extends 'Cucumber::Messages::Message';
1620              
1621 3     3   1014 use Scalar::Util qw( blessed );
  3         6  
  3         481  
1622              
1623             my %types = (
1624             background => 'Cucumber::Messages::Background',
1625             scenario => 'Cucumber::Messages::Scenario',
1626             );
1627              
1628             # This is a work-around for the fact that Moo doesn't have introspection
1629             # and Perl doesn't have boolean values...
1630             sub _types {
1631 0     0     return \%types;
1632             }
1633              
1634              
1635              
1636             =head4 background
1637              
1638              
1639             =cut
1640              
1641             has background =>
1642             (is => 'ro',
1643             );
1644              
1645              
1646             =head4 scenario
1647              
1648              
1649             =cut
1650              
1651             has scenario =>
1652             (is => 'ro',
1653             );
1654              
1655              
1656             }
1657              
1658             package Cucumber::Messages::Scenario {
1659             $Cucumber::Messages::Scenario::VERSION = '34.0.1';
1660             =head2 Cucumber::Messages::Scenario
1661              
1662             =head3 DESCRIPTION
1663              
1664             Represents the Scenario message in Cucumber's
1665             L.
1666              
1667              
1668              
1669             =head3 ATTRIBUTES
1670              
1671             =cut
1672              
1673 3     3   21 use Moo;
  3         6  
  3         11  
1674             extends 'Cucumber::Messages::Message';
1675              
1676 3     3   1143 use Scalar::Util qw( blessed );
  3         27  
  3         977  
1677              
1678             my %types = (
1679             location => 'Cucumber::Messages::Location',
1680             tags => '[]Cucumber::Messages::Tag',
1681             keyword => 'string',
1682             name => 'string',
1683             description => 'string',
1684             steps => '[]Cucumber::Messages::Step',
1685             examples => '[]Cucumber::Messages::Examples',
1686             id => 'string',
1687             );
1688              
1689             # This is a work-around for the fact that Moo doesn't have introspection
1690             # and Perl doesn't have boolean values...
1691             sub _types {
1692 0     0     return \%types;
1693             }
1694              
1695              
1696              
1697             =head4 location
1698              
1699             The location of the `Scenario` keyword
1700             =cut
1701              
1702             has location =>
1703             (is => 'ro',
1704             required => 1,
1705             default => sub { Cucumber::Messages::Location->new() },
1706             );
1707              
1708              
1709             =head4 tags
1710              
1711              
1712             =cut
1713              
1714             has tags =>
1715             (is => 'ro',
1716             required => 1,
1717             default => sub { [] },
1718             );
1719              
1720              
1721             =head4 keyword
1722              
1723              
1724             =cut
1725              
1726             has keyword =>
1727             (is => 'ro',
1728             required => 1,
1729             default => sub { '' },
1730             );
1731              
1732              
1733             =head4 name
1734              
1735              
1736             =cut
1737              
1738             has name =>
1739             (is => 'ro',
1740             required => 1,
1741             default => sub { '' },
1742             );
1743              
1744              
1745             =head4 description
1746              
1747              
1748             =cut
1749              
1750             has description =>
1751             (is => 'ro',
1752             required => 1,
1753             default => sub { '' },
1754             );
1755              
1756              
1757             =head4 steps
1758              
1759              
1760             =cut
1761              
1762             has steps =>
1763             (is => 'ro',
1764             required => 1,
1765             default => sub { [] },
1766             );
1767              
1768              
1769             =head4 examples
1770              
1771              
1772             =cut
1773              
1774             has examples =>
1775             (is => 'ro',
1776             required => 1,
1777             default => sub { [] },
1778             );
1779              
1780              
1781             =head4 id
1782              
1783              
1784             =cut
1785              
1786             has id =>
1787             (is => 'ro',
1788             required => 1,
1789             default => sub { '' },
1790             );
1791              
1792              
1793             }
1794              
1795             package Cucumber::Messages::Step {
1796             $Cucumber::Messages::Step::VERSION = '34.0.1';
1797             =head2 Cucumber::Messages::Step
1798              
1799             =head3 DESCRIPTION
1800              
1801             Represents the Step message in Cucumber's
1802             L.
1803              
1804             A step
1805              
1806             =head3 ATTRIBUTES
1807              
1808             =cut
1809              
1810 3     3   22 use Moo;
  3         6  
  3         13  
1811             extends 'Cucumber::Messages::Message';
1812              
1813 3     3   1264 use Scalar::Util qw( blessed );
  3         5  
  3         734  
1814              
1815             my %types = (
1816             location => 'Cucumber::Messages::Location',
1817             keyword => 'string',
1818             keyword_type => '',
1819             text => 'string',
1820             doc_string => 'Cucumber::Messages::DocString',
1821             data_table => 'Cucumber::Messages::DataTable',
1822             id => 'string',
1823             );
1824              
1825             # This is a work-around for the fact that Moo doesn't have introspection
1826             # and Perl doesn't have boolean values...
1827             sub _types {
1828 0     0     return \%types;
1829             }
1830              
1831              
1832              
1833             =head4 location
1834              
1835             The location of the steps' `keyword`
1836             =cut
1837              
1838             has location =>
1839             (is => 'ro',
1840             required => 1,
1841             default => sub { Cucumber::Messages::Location->new() },
1842             );
1843              
1844              
1845             =head4 keyword
1846              
1847             The actual keyword as it appeared in the source.
1848             =cut
1849              
1850             has keyword =>
1851             (is => 'ro',
1852             required => 1,
1853             default => sub { '' },
1854             );
1855              
1856              
1857             =head4 keyword_type
1858              
1859             The test phase signalled by the keyword: Context definition (Given), Action performance (When), Outcome assertion (Then). Other keywords signal Continuation (And and But) from a prior keyword. Please note that all translations which a dialect maps to multiple keywords (`*` is in this category for all dialects), map to 'Unknown'.
1860              
1861             Available constants for valid values of this field:
1862              
1863             =over
1864              
1865             =item * KEYWORDTYPE_UNKNOWN
1866              
1867             =item * KEYWORDTYPE_CONTEXT
1868              
1869             =item * KEYWORDTYPE_ACTION
1870              
1871             =item * KEYWORDTYPE_OUTCOME
1872              
1873             =item * KEYWORDTYPE_CONJUNCTION
1874              
1875             =back
1876              
1877             =cut
1878              
1879              
1880             use constant {
1881 3         734 KEYWORDTYPE_UNKNOWN => 'Unknown',
1882             KEYWORDTYPE_CONTEXT => 'Context',
1883             KEYWORDTYPE_ACTION => 'Action',
1884             KEYWORDTYPE_OUTCOME => 'Outcome',
1885             KEYWORDTYPE_CONJUNCTION => 'Conjunction',
1886 3     3   27 };
  3         7  
1887              
1888             has keyword_type =>
1889             (is => 'ro',
1890             );
1891              
1892              
1893             =head4 text
1894              
1895              
1896             =cut
1897              
1898             has text =>
1899             (is => 'ro',
1900             required => 1,
1901             default => sub { '' },
1902             );
1903              
1904              
1905             =head4 doc_string
1906              
1907              
1908             =cut
1909              
1910             has doc_string =>
1911             (is => 'ro',
1912             );
1913              
1914              
1915             =head4 data_table
1916              
1917              
1918             =cut
1919              
1920             has data_table =>
1921             (is => 'ro',
1922             );
1923              
1924              
1925             =head4 id
1926              
1927             Unique ID to be able to reference the Step from PickleStep
1928             =cut
1929              
1930             has id =>
1931             (is => 'ro',
1932             required => 1,
1933             default => sub { '' },
1934             );
1935              
1936              
1937             }
1938              
1939             package Cucumber::Messages::TableCell {
1940             $Cucumber::Messages::TableCell::VERSION = '34.0.1';
1941             =head2 Cucumber::Messages::TableCell
1942              
1943             =head3 DESCRIPTION
1944              
1945             Represents the TableCell message in Cucumber's
1946             L.
1947              
1948             A cell in a `TableRow`
1949              
1950             =head3 ATTRIBUTES
1951              
1952             =cut
1953              
1954 3     3   37 use Moo;
  3         5  
  3         13  
1955             extends 'Cucumber::Messages::Message';
1956              
1957 3     3   1168 use Scalar::Util qw( blessed );
  3         6  
  3         766  
1958              
1959             my %types = (
1960             location => 'Cucumber::Messages::Location',
1961             value => 'string',
1962             );
1963              
1964             # This is a work-around for the fact that Moo doesn't have introspection
1965             # and Perl doesn't have boolean values...
1966             sub _types {
1967 0     0     return \%types;
1968             }
1969              
1970              
1971              
1972             =head4 location
1973              
1974             The location of the cell
1975             =cut
1976              
1977             has location =>
1978             (is => 'ro',
1979             required => 1,
1980             default => sub { Cucumber::Messages::Location->new() },
1981             );
1982              
1983              
1984             =head4 value
1985              
1986             The value of the cell
1987             =cut
1988              
1989             has value =>
1990             (is => 'ro',
1991             required => 1,
1992             default => sub { '' },
1993             );
1994              
1995              
1996             }
1997              
1998             package Cucumber::Messages::TableRow {
1999             $Cucumber::Messages::TableRow::VERSION = '34.0.1';
2000             =head2 Cucumber::Messages::TableRow
2001              
2002             =head3 DESCRIPTION
2003              
2004             Represents the TableRow message in Cucumber's
2005             L.
2006              
2007             A row in a table
2008              
2009             =head3 ATTRIBUTES
2010              
2011             =cut
2012              
2013 3     3   24 use Moo;
  3         6  
  3         14  
2014             extends 'Cucumber::Messages::Message';
2015              
2016 3     3   1211 use Scalar::Util qw( blessed );
  3         5  
  3         840  
2017              
2018             my %types = (
2019             location => 'Cucumber::Messages::Location',
2020             cells => '[]Cucumber::Messages::TableCell',
2021             id => 'string',
2022             );
2023              
2024             # This is a work-around for the fact that Moo doesn't have introspection
2025             # and Perl doesn't have boolean values...
2026             sub _types {
2027 0     0     return \%types;
2028             }
2029              
2030              
2031              
2032             =head4 location
2033              
2034             The location of the first cell in the row
2035             =cut
2036              
2037             has location =>
2038             (is => 'ro',
2039             required => 1,
2040             default => sub { Cucumber::Messages::Location->new() },
2041             );
2042              
2043              
2044             =head4 cells
2045              
2046             Cells in the row
2047             =cut
2048              
2049             has cells =>
2050             (is => 'ro',
2051             required => 1,
2052             default => sub { [] },
2053             );
2054              
2055              
2056             =head4 id
2057              
2058              
2059             =cut
2060              
2061             has id =>
2062             (is => 'ro',
2063             required => 1,
2064             default => sub { '' },
2065             );
2066              
2067              
2068             }
2069              
2070             package Cucumber::Messages::Tag {
2071             $Cucumber::Messages::Tag::VERSION = '34.0.1';
2072             =head2 Cucumber::Messages::Tag
2073              
2074             =head3 DESCRIPTION
2075              
2076             Represents the Tag message in Cucumber's
2077             L.
2078              
2079             A tag
2080              
2081             =head3 ATTRIBUTES
2082              
2083             =cut
2084              
2085 3     3   25 use Moo;
  3         11  
  3         14  
2086             extends 'Cucumber::Messages::Message';
2087              
2088 3     3   1211 use Scalar::Util qw( blessed );
  3         7  
  3         677  
2089              
2090             my %types = (
2091             location => 'Cucumber::Messages::Location',
2092             name => 'string',
2093             id => 'string',
2094             );
2095              
2096             # This is a work-around for the fact that Moo doesn't have introspection
2097             # and Perl doesn't have boolean values...
2098             sub _types {
2099 0     0     return \%types;
2100             }
2101              
2102              
2103              
2104             =head4 location
2105              
2106             Location of the tag
2107             =cut
2108              
2109             has location =>
2110             (is => 'ro',
2111             required => 1,
2112             default => sub { Cucumber::Messages::Location->new() },
2113             );
2114              
2115              
2116             =head4 name
2117              
2118             The name of the tag (including the leading `@`)
2119             =cut
2120              
2121             has name =>
2122             (is => 'ro',
2123             required => 1,
2124             default => sub { '' },
2125             );
2126              
2127              
2128             =head4 id
2129              
2130             Unique ID to be able to reference the Tag from PickleTag
2131             =cut
2132              
2133             has id =>
2134             (is => 'ro',
2135             required => 1,
2136             default => sub { '' },
2137             );
2138              
2139              
2140             }
2141              
2142             package Cucumber::Messages::Hook {
2143             $Cucumber::Messages::Hook::VERSION = '34.0.1';
2144             =head2 Cucumber::Messages::Hook
2145              
2146             =head3 DESCRIPTION
2147              
2148             Represents the Hook message in Cucumber's
2149             L.
2150              
2151              
2152              
2153             =head3 ATTRIBUTES
2154              
2155             =cut
2156              
2157 3     3   26 use Moo;
  3         5  
  3         14  
2158             extends 'Cucumber::Messages::Message';
2159              
2160 3     3   1252 use Scalar::Util qw( blessed );
  3         6  
  3         684  
2161              
2162             my %types = (
2163             id => 'string',
2164             name => 'string',
2165             source_reference => 'Cucumber::Messages::SourceReference',
2166             tag_expression => 'string',
2167             type => '',
2168             );
2169              
2170             # This is a work-around for the fact that Moo doesn't have introspection
2171             # and Perl doesn't have boolean values...
2172             sub _types {
2173 0     0     return \%types;
2174             }
2175              
2176              
2177              
2178             =head4 id
2179              
2180              
2181             =cut
2182              
2183             has id =>
2184             (is => 'ro',
2185             required => 1,
2186             default => sub { '' },
2187             );
2188              
2189              
2190             =head4 name
2191              
2192              
2193             =cut
2194              
2195             has name =>
2196             (is => 'ro',
2197             );
2198              
2199              
2200             =head4 source_reference
2201              
2202              
2203             =cut
2204              
2205             has source_reference =>
2206             (is => 'ro',
2207             required => 1,
2208             default => sub { Cucumber::Messages::SourceReference->new() },
2209             );
2210              
2211              
2212             =head4 tag_expression
2213              
2214              
2215             =cut
2216              
2217             has tag_expression =>
2218             (is => 'ro',
2219             );
2220              
2221              
2222             =head4 type
2223              
2224              
2225              
2226             Available constants for valid values of this field:
2227              
2228             =over
2229              
2230             =item * TYPE_BEFORE_TEST_RUN
2231              
2232             =item * TYPE_AFTER_TEST_RUN
2233              
2234             =item * TYPE_BEFORE_TEST_CASE
2235              
2236             =item * TYPE_AFTER_TEST_CASE
2237              
2238             =item * TYPE_BEFORE_TEST_STEP
2239              
2240             =item * TYPE_AFTER_TEST_STEP
2241              
2242             =back
2243              
2244             =cut
2245              
2246              
2247             use constant {
2248 3         459 TYPE_BEFORE_TEST_RUN => 'BEFORE_TEST_RUN',
2249             TYPE_AFTER_TEST_RUN => 'AFTER_TEST_RUN',
2250             TYPE_BEFORE_TEST_CASE => 'BEFORE_TEST_CASE',
2251             TYPE_AFTER_TEST_CASE => 'AFTER_TEST_CASE',
2252             TYPE_BEFORE_TEST_STEP => 'BEFORE_TEST_STEP',
2253             TYPE_AFTER_TEST_STEP => 'AFTER_TEST_STEP',
2254 3     3   23 };
  3         6  
2255              
2256             has type =>
2257             (is => 'ro',
2258             );
2259              
2260              
2261             }
2262              
2263             package Cucumber::Messages::Location {
2264             $Cucumber::Messages::Location::VERSION = '34.0.1';
2265             =head2 Cucumber::Messages::Location
2266              
2267             =head3 DESCRIPTION
2268              
2269             Represents the Location message in Cucumber's
2270             L.
2271              
2272             Points to a line and a column in a text file
2273              
2274             =head3 ATTRIBUTES
2275              
2276             =cut
2277              
2278 3     3   20 use Moo;
  3         11  
  3         14  
2279             extends 'Cucumber::Messages::Message';
2280              
2281 3     3   1145 use Scalar::Util qw( blessed );
  3         6  
  3         648  
2282              
2283             my %types = (
2284             line => 'number',
2285             column => 'number',
2286             );
2287              
2288             # This is a work-around for the fact that Moo doesn't have introspection
2289             # and Perl doesn't have boolean values...
2290             sub _types {
2291 0     0     return \%types;
2292             }
2293              
2294              
2295              
2296             =head4 line
2297              
2298              
2299             =cut
2300              
2301             has line =>
2302             (is => 'ro',
2303             required => 1,
2304             default => sub { 0 },
2305             );
2306              
2307              
2308             =head4 column
2309              
2310              
2311             =cut
2312              
2313             has column =>
2314             (is => 'ro',
2315             );
2316              
2317              
2318             }
2319              
2320             package Cucumber::Messages::Meta {
2321             $Cucumber::Messages::Meta::VERSION = '34.0.1';
2322             =head2 Cucumber::Messages::Meta
2323              
2324             =head3 DESCRIPTION
2325              
2326             Represents the Meta message in Cucumber's
2327             L.
2328              
2329             This message contains meta information about the environment. Consumers can use
2330             this for various purposes.
2331              
2332             =head3 ATTRIBUTES
2333              
2334             =cut
2335              
2336 3     3   22 use Moo;
  3         7  
  3         13  
2337             extends 'Cucumber::Messages::Message';
2338              
2339 3     3   1242 use Scalar::Util qw( blessed );
  3         12  
  3         939  
2340              
2341             my %types = (
2342             protocol_version => 'string',
2343             implementation => 'Cucumber::Messages::Product',
2344             runtime => 'Cucumber::Messages::Product',
2345             os => 'Cucumber::Messages::Product',
2346             cpu => 'Cucumber::Messages::Product',
2347             ci => 'Cucumber::Messages::Ci',
2348             );
2349              
2350             # This is a work-around for the fact that Moo doesn't have introspection
2351             # and Perl doesn't have boolean values...
2352             sub _types {
2353 0     0     return \%types;
2354             }
2355              
2356              
2357              
2358             =head4 protocol_version
2359              
2360             The [SEMVER](https://semver.org/) version number of the protocol
2361             =cut
2362              
2363             has protocol_version =>
2364             (is => 'ro',
2365             required => 1,
2366             default => sub { '' },
2367             );
2368              
2369              
2370             =head4 implementation
2371              
2372             SpecFlow, Cucumber-JVM, Cucumber.js, Cucumber-Ruby, Behat etc.
2373             =cut
2374              
2375             has implementation =>
2376             (is => 'ro',
2377             required => 1,
2378             default => sub { Cucumber::Messages::Product->new() },
2379             );
2380              
2381              
2382             =head4 runtime
2383              
2384             Java, Ruby, Node.js etc
2385             =cut
2386              
2387             has runtime =>
2388             (is => 'ro',
2389             required => 1,
2390             default => sub { Cucumber::Messages::Product->new() },
2391             );
2392              
2393              
2394             =head4 os
2395              
2396             Windows, Linux, MacOS etc
2397             =cut
2398              
2399             has os =>
2400             (is => 'ro',
2401             required => 1,
2402             default => sub { Cucumber::Messages::Product->new() },
2403             );
2404              
2405              
2406             =head4 cpu
2407              
2408             386, arm, amd64 etc
2409             =cut
2410              
2411             has cpu =>
2412             (is => 'ro',
2413             required => 1,
2414             default => sub { Cucumber::Messages::Product->new() },
2415             );
2416              
2417              
2418             =head4 ci
2419              
2420              
2421             =cut
2422              
2423             has ci =>
2424             (is => 'ro',
2425             );
2426              
2427              
2428             }
2429              
2430             package Cucumber::Messages::Ci {
2431             $Cucumber::Messages::Ci::VERSION = '34.0.1';
2432             =head2 Cucumber::Messages::Ci
2433              
2434             =head3 DESCRIPTION
2435              
2436             Represents the Ci message in Cucumber's
2437             L.
2438              
2439             CI environment
2440              
2441             =head3 ATTRIBUTES
2442              
2443             =cut
2444              
2445 3     3   46 use Moo;
  3         25  
  3         13  
2446             extends 'Cucumber::Messages::Message';
2447              
2448 3     3   996 use Scalar::Util qw( blessed );
  3         40  
  3         598  
2449              
2450             my %types = (
2451             name => 'string',
2452             url => 'string',
2453             build_number => 'string',
2454             git => 'Cucumber::Messages::Git',
2455             );
2456              
2457             # This is a work-around for the fact that Moo doesn't have introspection
2458             # and Perl doesn't have boolean values...
2459             sub _types {
2460 0     0     return \%types;
2461             }
2462              
2463              
2464              
2465             =head4 name
2466              
2467             Name of the CI product, e.g. "Jenkins", "CircleCI" etc.
2468             =cut
2469              
2470             has name =>
2471             (is => 'ro',
2472             required => 1,
2473             default => sub { '' },
2474             );
2475              
2476              
2477             =head4 url
2478              
2479             Link to the build
2480             =cut
2481              
2482             has url =>
2483             (is => 'ro',
2484             );
2485              
2486              
2487             =head4 build_number
2488              
2489             The build number. Some CI servers use non-numeric build numbers, which is why this is a string
2490             =cut
2491              
2492             has build_number =>
2493             (is => 'ro',
2494             );
2495              
2496              
2497             =head4 git
2498              
2499              
2500             =cut
2501              
2502             has git =>
2503             (is => 'ro',
2504             );
2505              
2506              
2507             }
2508              
2509             package Cucumber::Messages::Git {
2510             $Cucumber::Messages::Git::VERSION = '34.0.1';
2511             =head2 Cucumber::Messages::Git
2512              
2513             =head3 DESCRIPTION
2514              
2515             Represents the Git message in Cucumber's
2516             L.
2517              
2518             Information about Git, provided by the Build/CI server as environment
2519             variables.
2520              
2521             =head3 ATTRIBUTES
2522              
2523             =cut
2524              
2525 3     3   20 use Moo;
  3         5  
  3         11  
2526             extends 'Cucumber::Messages::Message';
2527              
2528 3     3   1034 use Scalar::Util qw( blessed );
  3         6  
  3         609  
2529              
2530             my %types = (
2531             remote => 'string',
2532             revision => 'string',
2533             branch => 'string',
2534             tag => 'string',
2535             );
2536              
2537             # This is a work-around for the fact that Moo doesn't have introspection
2538             # and Perl doesn't have boolean values...
2539             sub _types {
2540 0     0     return \%types;
2541             }
2542              
2543              
2544              
2545             =head4 remote
2546              
2547              
2548             =cut
2549              
2550             has remote =>
2551             (is => 'ro',
2552             required => 1,
2553             default => sub { '' },
2554             );
2555              
2556              
2557             =head4 revision
2558              
2559              
2560             =cut
2561              
2562             has revision =>
2563             (is => 'ro',
2564             required => 1,
2565             default => sub { '' },
2566             );
2567              
2568              
2569             =head4 branch
2570              
2571              
2572             =cut
2573              
2574             has branch =>
2575             (is => 'ro',
2576             );
2577              
2578              
2579             =head4 tag
2580              
2581              
2582             =cut
2583              
2584             has tag =>
2585             (is => 'ro',
2586             );
2587              
2588              
2589             }
2590              
2591             package Cucumber::Messages::Product {
2592             $Cucumber::Messages::Product::VERSION = '34.0.1';
2593             =head2 Cucumber::Messages::Product
2594              
2595             =head3 DESCRIPTION
2596              
2597             Represents the Product message in Cucumber's
2598             L.
2599              
2600             Used to describe various properties of Meta
2601              
2602             =head3 ATTRIBUTES
2603              
2604             =cut
2605              
2606 3     3   19 use Moo;
  3         4  
  3         23  
2607             extends 'Cucumber::Messages::Message';
2608              
2609 3     3   776 use Scalar::Util qw( blessed );
  3         3  
  3         531  
2610              
2611             my %types = (
2612             name => 'string',
2613             version => 'string',
2614             );
2615              
2616             # This is a work-around for the fact that Moo doesn't have introspection
2617             # and Perl doesn't have boolean values...
2618             sub _types {
2619 0     0     return \%types;
2620             }
2621              
2622              
2623              
2624             =head4 name
2625              
2626             The product name
2627             =cut
2628              
2629             has name =>
2630             (is => 'ro',
2631             required => 1,
2632             default => sub { '' },
2633             );
2634              
2635              
2636             =head4 version
2637              
2638             The product version
2639             =cut
2640              
2641             has version =>
2642             (is => 'ro',
2643             );
2644              
2645              
2646             }
2647              
2648             package Cucumber::Messages::ParameterType {
2649             $Cucumber::Messages::ParameterType::VERSION = '34.0.1';
2650             =head2 Cucumber::Messages::ParameterType
2651              
2652             =head3 DESCRIPTION
2653              
2654             Represents the ParameterType message in Cucumber's
2655             L.
2656              
2657              
2658              
2659             =head3 ATTRIBUTES
2660              
2661             =cut
2662              
2663 3     3   36 use Moo;
  3         5  
  3         9  
2664             extends 'Cucumber::Messages::Message';
2665              
2666 3     3   947 use Scalar::Util qw( blessed );
  3         5  
  3         568  
2667              
2668             my %types = (
2669             name => 'string',
2670             regular_expressions => '[]string',
2671             prefer_for_regular_expression_match => 'boolean',
2672             use_for_snippets => 'boolean',
2673             id => 'string',
2674             source_reference => 'Cucumber::Messages::SourceReference',
2675             );
2676              
2677             # This is a work-around for the fact that Moo doesn't have introspection
2678             # and Perl doesn't have boolean values...
2679             sub _types {
2680 0     0     return \%types;
2681             }
2682              
2683              
2684              
2685             =head4 name
2686              
2687             The name is unique, so we don't need an id.
2688             =cut
2689              
2690             has name =>
2691             (is => 'ro',
2692             required => 1,
2693             default => sub { '' },
2694             );
2695              
2696              
2697             =head4 regular_expressions
2698              
2699              
2700             =cut
2701              
2702             has regular_expressions =>
2703             (is => 'ro',
2704             required => 1,
2705             default => sub { [] },
2706             );
2707              
2708              
2709             =head4 prefer_for_regular_expression_match
2710              
2711              
2712             =cut
2713              
2714             has prefer_for_regular_expression_match =>
2715             (is => 'ro',
2716             required => 1,
2717             default => sub { '' },
2718             );
2719              
2720              
2721             =head4 use_for_snippets
2722              
2723              
2724             =cut
2725              
2726             has use_for_snippets =>
2727             (is => 'ro',
2728             required => 1,
2729             default => sub { '' },
2730             );
2731              
2732              
2733             =head4 id
2734              
2735              
2736             =cut
2737              
2738             has id =>
2739             (is => 'ro',
2740             required => 1,
2741             default => sub { '' },
2742             );
2743              
2744              
2745             =head4 source_reference
2746              
2747              
2748             =cut
2749              
2750             has source_reference =>
2751             (is => 'ro',
2752             );
2753              
2754              
2755             }
2756              
2757             package Cucumber::Messages::ParseError {
2758             $Cucumber::Messages::ParseError::VERSION = '34.0.1';
2759             =head2 Cucumber::Messages::ParseError
2760              
2761             =head3 DESCRIPTION
2762              
2763             Represents the ParseError message in Cucumber's
2764             L.
2765              
2766              
2767              
2768             =head3 ATTRIBUTES
2769              
2770             =cut
2771              
2772 3     3   15 use Moo;
  3         3  
  3         10  
2773             extends 'Cucumber::Messages::Message';
2774              
2775 3     3   841 use Scalar::Util qw( blessed );
  3         6  
  3         393  
2776              
2777             my %types = (
2778             source => 'Cucumber::Messages::SourceReference',
2779             message => 'string',
2780             );
2781              
2782             # This is a work-around for the fact that Moo doesn't have introspection
2783             # and Perl doesn't have boolean values...
2784             sub _types {
2785 0     0     return \%types;
2786             }
2787              
2788              
2789              
2790             =head4 source
2791              
2792              
2793             =cut
2794              
2795             has source =>
2796             (is => 'ro',
2797             required => 1,
2798             default => sub { Cucumber::Messages::SourceReference->new() },
2799             );
2800              
2801              
2802             =head4 message
2803              
2804              
2805             =cut
2806              
2807             has message =>
2808             (is => 'ro',
2809             required => 1,
2810             default => sub { '' },
2811             );
2812              
2813              
2814             }
2815              
2816             package Cucumber::Messages::Pickle {
2817             $Cucumber::Messages::Pickle::VERSION = '34.0.1';
2818             =head2 Cucumber::Messages::Pickle
2819              
2820             =head3 DESCRIPTION
2821              
2822             Represents the Pickle message in Cucumber's
2823             L.
2824              
2825             A `Pickle` represents a template for a `TestCase`. It is typically derived
2826             from another format, such as [GherkinDocument](#io.cucumber.messages.GherkinDocument).
2827             In the future a `Pickle` may be derived from other formats such as Markdown or
2828             Excel files.
2829              
2830             By making `Pickle` the main data structure Cucumber uses for execution, the
2831             implementation of Cucumber itself becomes simpler, as it doesn't have to deal
2832             with the complex structure of a [GherkinDocument](#io.cucumber.messages.GherkinDocument).
2833              
2834             Each `PickleStep` of a `Pickle` is matched with a `StepDefinition` to create a `TestCase`
2835              
2836             =head3 ATTRIBUTES
2837              
2838             =cut
2839              
2840 3     3   13 use Moo;
  3         5  
  3         13  
2841             extends 'Cucumber::Messages::Message';
2842              
2843 3     3   963 use Scalar::Util qw( blessed );
  3         4  
  3         843  
2844              
2845             my %types = (
2846             id => 'string',
2847             uri => 'string',
2848             location => 'Cucumber::Messages::Location',
2849             name => 'string',
2850             language => 'string',
2851             steps => '[]Cucumber::Messages::PickleStep',
2852             tags => '[]Cucumber::Messages::PickleTag',
2853             ast_node_ids => '[]string',
2854             );
2855              
2856             # This is a work-around for the fact that Moo doesn't have introspection
2857             # and Perl doesn't have boolean values...
2858             sub _types {
2859 0     0     return \%types;
2860             }
2861              
2862              
2863              
2864             =head4 id
2865              
2866             A unique id for the pickle
2867             =cut
2868              
2869             has id =>
2870             (is => 'ro',
2871             required => 1,
2872             default => sub { '' },
2873             );
2874              
2875              
2876             =head4 uri
2877              
2878             The uri of the source file
2879             =cut
2880              
2881             has uri =>
2882             (is => 'ro',
2883             required => 1,
2884             default => sub { '' },
2885             );
2886              
2887              
2888             =head4 location
2889              
2890             The location of this pickle in source file. A pickle constructed from `Examples` will point to the example row.
2891             =cut
2892              
2893             has location =>
2894             (is => 'ro',
2895             );
2896              
2897              
2898             =head4 name
2899              
2900             The name of the pickle
2901             =cut
2902              
2903             has name =>
2904             (is => 'ro',
2905             required => 1,
2906             default => sub { '' },
2907             );
2908              
2909              
2910             =head4 language
2911              
2912             The language of the pickle
2913             =cut
2914              
2915             has language =>
2916             (is => 'ro',
2917             required => 1,
2918             default => sub { '' },
2919             );
2920              
2921              
2922             =head4 steps
2923              
2924             One or more steps
2925             =cut
2926              
2927             has steps =>
2928             (is => 'ro',
2929             required => 1,
2930             default => sub { [] },
2931             );
2932              
2933              
2934             =head4 tags
2935              
2936             One or more tags. If this pickle is constructed from a Gherkin document,
2937             It includes inherited tags from the `Feature` as well.
2938             =cut
2939              
2940             has tags =>
2941             (is => 'ro',
2942             required => 1,
2943             default => sub { [] },
2944             );
2945              
2946              
2947             =head4 ast_node_ids
2948              
2949             Points to the AST node locations of the pickle. The last one represents the unique
2950             id of the pickle. A pickle constructed from `Examples` will have the first
2951             id originating from the `Scenario` AST node, and the second from the `TableRow` AST node.
2952             =cut
2953              
2954             has ast_node_ids =>
2955             (is => 'ro',
2956             required => 1,
2957             default => sub { [] },
2958             );
2959              
2960              
2961             }
2962              
2963             package Cucumber::Messages::PickleDocString {
2964             $Cucumber::Messages::PickleDocString::VERSION = '34.0.1';
2965             =head2 Cucumber::Messages::PickleDocString
2966              
2967             =head3 DESCRIPTION
2968              
2969             Represents the PickleDocString message in Cucumber's
2970             L.
2971              
2972              
2973              
2974             =head3 ATTRIBUTES
2975              
2976             =cut
2977              
2978 3     3   21 use Moo;
  3         5  
  3         16  
2979             extends 'Cucumber::Messages::Message';
2980              
2981 3     3   1099 use Scalar::Util qw( blessed );
  3         6  
  3         528  
2982              
2983             my %types = (
2984             argument_index => 'number',
2985             media_type => 'string',
2986             content => 'string',
2987             );
2988              
2989             # This is a work-around for the fact that Moo doesn't have introspection
2990             # and Perl doesn't have boolean values...
2991             sub _types {
2992 0     0     return \%types;
2993             }
2994              
2995              
2996              
2997             =head4 argument_index
2998              
2999              
3000             =cut
3001              
3002             has argument_index =>
3003             (is => 'ro',
3004             );
3005              
3006              
3007             =head4 media_type
3008              
3009              
3010             =cut
3011              
3012             has media_type =>
3013             (is => 'ro',
3014             );
3015              
3016              
3017             =head4 content
3018              
3019              
3020             =cut
3021              
3022             has content =>
3023             (is => 'ro',
3024             required => 1,
3025             default => sub { '' },
3026             );
3027              
3028              
3029             }
3030              
3031             package Cucumber::Messages::PickleStep {
3032             $Cucumber::Messages::PickleStep::VERSION = '34.0.1';
3033             =head2 Cucumber::Messages::PickleStep
3034              
3035             =head3 DESCRIPTION
3036              
3037             Represents the PickleStep message in Cucumber's
3038             L.
3039              
3040             An executable step
3041              
3042             =head3 ATTRIBUTES
3043              
3044             =cut
3045              
3046 3     3   20 use Moo;
  3         4  
  3         13  
3047             extends 'Cucumber::Messages::Message';
3048              
3049 3     3   1182 use Scalar::Util qw( blessed );
  3         6  
  3         649  
3050              
3051             my %types = (
3052             argument => 'Cucumber::Messages::PickleStepArgument',
3053             ast_node_ids => '[]string',
3054             id => 'string',
3055             type => '',
3056             text => 'string',
3057             );
3058              
3059             # This is a work-around for the fact that Moo doesn't have introspection
3060             # and Perl doesn't have boolean values...
3061             sub _types {
3062 0     0     return \%types;
3063             }
3064              
3065              
3066              
3067             =head4 argument
3068              
3069             The first argument for this step, if any
3070             =cut
3071              
3072             has argument =>
3073             (is => 'ro',
3074             );
3075              
3076              
3077             =head4 ast_node_ids
3078              
3079             References the IDs of the source of the step. For Gherkin, this can be
3080             the ID of a Step, and possibly also the ID of a TableRow
3081             =cut
3082              
3083             has ast_node_ids =>
3084             (is => 'ro',
3085             required => 1,
3086             default => sub { [] },
3087             );
3088              
3089              
3090             =head4 id
3091              
3092             A unique ID for the PickleStep
3093             =cut
3094              
3095             has id =>
3096             (is => 'ro',
3097             required => 1,
3098             default => sub { '' },
3099             );
3100              
3101              
3102             =head4 type
3103              
3104             The context in which the step was specified: context (Given), action (When) or outcome (Then).
3105              
3106             Note that the keywords `But` and `And` inherit their meaning from prior steps and the `*` 'keyword' doesn't have specific meaning (hence Unknown)
3107              
3108             Available constants for valid values of this field:
3109              
3110             =over
3111              
3112             =item * TYPE_UNKNOWN
3113              
3114             =item * TYPE_CONTEXT
3115              
3116             =item * TYPE_ACTION
3117              
3118             =item * TYPE_OUTCOME
3119              
3120             =back
3121              
3122             =cut
3123              
3124              
3125             use constant {
3126 3         662 TYPE_UNKNOWN => 'Unknown',
3127             TYPE_CONTEXT => 'Context',
3128             TYPE_ACTION => 'Action',
3129             TYPE_OUTCOME => 'Outcome',
3130 3     3   24 };
  3         6  
3131              
3132             has type =>
3133             (is => 'ro',
3134             );
3135              
3136              
3137             =head4 text
3138              
3139              
3140             =cut
3141              
3142             has text =>
3143             (is => 'ro',
3144             required => 1,
3145             default => sub { '' },
3146             );
3147              
3148              
3149             }
3150              
3151             package Cucumber::Messages::PickleStepArgument {
3152             $Cucumber::Messages::PickleStepArgument::VERSION = '34.0.1';
3153             =head2 Cucumber::Messages::PickleStepArgument
3154              
3155             =head3 DESCRIPTION
3156              
3157             Represents the PickleStepArgument message in Cucumber's
3158             L.
3159              
3160             Optional arguments. Either a PickleDocString, PickleTable or both
3161              
3162             =head3 ATTRIBUTES
3163              
3164             =cut
3165              
3166 3     3   19 use Moo;
  3         12  
  3         20  
3167             extends 'Cucumber::Messages::Message';
3168              
3169 3     3   1051 use Scalar::Util qw( blessed );
  3         5  
  3         406  
3170              
3171             my %types = (
3172             doc_string => 'Cucumber::Messages::PickleDocString',
3173             data_table => 'Cucumber::Messages::PickleTable',
3174             );
3175              
3176             # This is a work-around for the fact that Moo doesn't have introspection
3177             # and Perl doesn't have boolean values...
3178             sub _types {
3179 0     0     return \%types;
3180             }
3181              
3182              
3183              
3184             =head4 doc_string
3185              
3186              
3187             =cut
3188              
3189             has doc_string =>
3190             (is => 'ro',
3191             );
3192              
3193              
3194             =head4 data_table
3195              
3196              
3197             =cut
3198              
3199             has data_table =>
3200             (is => 'ro',
3201             );
3202              
3203              
3204             }
3205              
3206             package Cucumber::Messages::PickleTable {
3207             $Cucumber::Messages::PickleTable::VERSION = '34.0.1';
3208             =head2 Cucumber::Messages::PickleTable
3209              
3210             =head3 DESCRIPTION
3211              
3212             Represents the PickleTable message in Cucumber's
3213             L.
3214              
3215              
3216              
3217             =head3 ATTRIBUTES
3218              
3219             =cut
3220              
3221 3     3   15 use Moo;
  3         5  
  3         12  
3222             extends 'Cucumber::Messages::Message';
3223              
3224 3     3   1052 use Scalar::Util qw( blessed );
  3         5  
  3         486  
3225              
3226             my %types = (
3227             argument_index => 'number',
3228             rows => '[]Cucumber::Messages::PickleTableRow',
3229             );
3230              
3231             # This is a work-around for the fact that Moo doesn't have introspection
3232             # and Perl doesn't have boolean values...
3233             sub _types {
3234 0     0     return \%types;
3235             }
3236              
3237              
3238              
3239             =head4 argument_index
3240              
3241              
3242             =cut
3243              
3244             has argument_index =>
3245             (is => 'ro',
3246             );
3247              
3248              
3249             =head4 rows
3250              
3251              
3252             =cut
3253              
3254             has rows =>
3255             (is => 'ro',
3256             required => 1,
3257             default => sub { [] },
3258             );
3259              
3260              
3261             }
3262              
3263             package Cucumber::Messages::PickleTableCell {
3264             $Cucumber::Messages::PickleTableCell::VERSION = '34.0.1';
3265             =head2 Cucumber::Messages::PickleTableCell
3266              
3267             =head3 DESCRIPTION
3268              
3269             Represents the PickleTableCell message in Cucumber's
3270             L.
3271              
3272              
3273              
3274             =head3 ATTRIBUTES
3275              
3276             =cut
3277              
3278 3     3   18 use Moo;
  3         4  
  3         12  
3279             extends 'Cucumber::Messages::Message';
3280              
3281 3     3   903 use Scalar::Util qw( blessed );
  3         5  
  3         467  
3282              
3283             my %types = (
3284             value => 'string',
3285             );
3286              
3287             # This is a work-around for the fact that Moo doesn't have introspection
3288             # and Perl doesn't have boolean values...
3289             sub _types {
3290 0     0     return \%types;
3291             }
3292              
3293              
3294              
3295             =head4 value
3296              
3297              
3298             =cut
3299              
3300             has value =>
3301             (is => 'ro',
3302             required => 1,
3303             default => sub { '' },
3304             );
3305              
3306              
3307             }
3308              
3309             package Cucumber::Messages::PickleTableRow {
3310             $Cucumber::Messages::PickleTableRow::VERSION = '34.0.1';
3311             =head2 Cucumber::Messages::PickleTableRow
3312              
3313             =head3 DESCRIPTION
3314              
3315             Represents the PickleTableRow message in Cucumber's
3316             L.
3317              
3318              
3319              
3320             =head3 ATTRIBUTES
3321              
3322             =cut
3323              
3324 3     3   18 use Moo;
  3         4  
  3         10  
3325             extends 'Cucumber::Messages::Message';
3326              
3327 3     3   846 use Scalar::Util qw( blessed );
  3         5  
  3         527  
3328              
3329             my %types = (
3330             cells => '[]Cucumber::Messages::PickleTableCell',
3331             );
3332              
3333             # This is a work-around for the fact that Moo doesn't have introspection
3334             # and Perl doesn't have boolean values...
3335             sub _types {
3336 0     0     return \%types;
3337             }
3338              
3339              
3340              
3341             =head4 cells
3342              
3343              
3344             =cut
3345              
3346             has cells =>
3347             (is => 'ro',
3348             required => 1,
3349             default => sub { [] },
3350             );
3351              
3352              
3353             }
3354              
3355             package Cucumber::Messages::PickleTag {
3356             $Cucumber::Messages::PickleTag::VERSION = '34.0.1';
3357             =head2 Cucumber::Messages::PickleTag
3358              
3359             =head3 DESCRIPTION
3360              
3361             Represents the PickleTag message in Cucumber's
3362             L.
3363              
3364             A tag
3365              
3366             =head3 ATTRIBUTES
3367              
3368             =cut
3369              
3370 3     3   30 use Moo;
  3         5  
  3         12  
3371             extends 'Cucumber::Messages::Message';
3372              
3373 3     3   1032 use Scalar::Util qw( blessed );
  3         10  
  3         607  
3374              
3375             my %types = (
3376             name => 'string',
3377             ast_node_id => 'string',
3378             );
3379              
3380             # This is a work-around for the fact that Moo doesn't have introspection
3381             # and Perl doesn't have boolean values...
3382             sub _types {
3383 0     0     return \%types;
3384             }
3385              
3386              
3387              
3388             =head4 name
3389              
3390              
3391             =cut
3392              
3393             has name =>
3394             (is => 'ro',
3395             required => 1,
3396             default => sub { '' },
3397             );
3398              
3399              
3400             =head4 ast_node_id
3401              
3402             Points to the AST node this was created from
3403             =cut
3404              
3405             has ast_node_id =>
3406             (is => 'ro',
3407             required => 1,
3408             default => sub { '' },
3409             );
3410              
3411              
3412             }
3413              
3414             package Cucumber::Messages::Source {
3415             $Cucumber::Messages::Source::VERSION = '34.0.1';
3416             =head2 Cucumber::Messages::Source
3417              
3418             =head3 DESCRIPTION
3419              
3420             Represents the Source message in Cucumber's
3421             L.
3422              
3423             A source file, typically a Gherkin document or Java/Ruby/JavaScript source code
3424              
3425             =head3 ATTRIBUTES
3426              
3427             =cut
3428              
3429 3     3   19 use Moo;
  3         5  
  3         12  
3430             extends 'Cucumber::Messages::Message';
3431              
3432 3     3   864 use Scalar::Util qw( blessed );
  3         5  
  3         430  
3433              
3434             my %types = (
3435             uri => 'string',
3436             data => 'string',
3437             media_type => '',
3438             );
3439              
3440             # This is a work-around for the fact that Moo doesn't have introspection
3441             # and Perl doesn't have boolean values...
3442             sub _types {
3443 0     0     return \%types;
3444             }
3445              
3446              
3447              
3448             =head4 uri
3449              
3450             The [URI](https://en.wikipedia.org/wiki/Uniform_Resource_Identifier)
3451             of the source, typically a file path relative to the root directory
3452             =cut
3453              
3454             has uri =>
3455             (is => 'ro',
3456             required => 1,
3457             default => sub { '' },
3458             );
3459              
3460              
3461             =head4 data
3462              
3463             The contents of the file
3464             =cut
3465              
3466             has data =>
3467             (is => 'ro',
3468             required => 1,
3469             default => sub { '' },
3470             );
3471              
3472              
3473             =head4 media_type
3474              
3475             The media type of the file. Can be used to specify custom types, such as
3476             text/x.cucumber.gherkin+plain
3477              
3478             Available constants for valid values of this field:
3479              
3480             =over
3481              
3482             =item * MEDIATYPE_TEXT_X_CUCUMBER_GHERKIN_PLAIN
3483              
3484             =item * MEDIATYPE_TEXT_X_CUCUMBER_GHERKIN_MARKDOWN
3485              
3486             =back
3487              
3488             =cut
3489              
3490              
3491             use constant {
3492 3         332 MEDIATYPE_TEXT_X_CUCUMBER_GHERKIN_PLAIN => 'text/x.cucumber.gherkin+plain',
3493             MEDIATYPE_TEXT_X_CUCUMBER_GHERKIN_MARKDOWN => 'text/x.cucumber.gherkin+markdown',
3494 3     3   15 };
  3         3  
3495              
3496             has media_type =>
3497             (is => 'ro',
3498             required => 1,
3499             default => sub { MEDIATYPE_TEXT_X_CUCUMBER_GHERKIN_PLAIN },
3500             );
3501              
3502              
3503             }
3504              
3505             package Cucumber::Messages::SourceReference {
3506             $Cucumber::Messages::SourceReference::VERSION = '34.0.1';
3507             =head2 Cucumber::Messages::SourceReference
3508              
3509             =head3 DESCRIPTION
3510              
3511             Represents the SourceReference message in Cucumber's
3512             L.
3513              
3514             Points to a [Source](#io.cucumber.messages.Source) identified by `uri` and a
3515             [Location](#io.cucumber.messages.Location) within that file.
3516              
3517             =head3 ATTRIBUTES
3518              
3519             =cut
3520              
3521 3     3   13 use Moo;
  3         4  
  3         9  
3522             extends 'Cucumber::Messages::Message';
3523              
3524 3     3   802 use Scalar::Util qw( blessed );
  3         4  
  3         426  
3525              
3526             my %types = (
3527             uri => 'string',
3528             java_method => 'Cucumber::Messages::JavaMethod',
3529             java_stack_trace_element => 'Cucumber::Messages::JavaStackTraceElement',
3530             location => 'Cucumber::Messages::Location',
3531             );
3532              
3533             # This is a work-around for the fact that Moo doesn't have introspection
3534             # and Perl doesn't have boolean values...
3535             sub _types {
3536 0     0     return \%types;
3537             }
3538              
3539              
3540              
3541             =head4 uri
3542              
3543              
3544             =cut
3545              
3546             has uri =>
3547             (is => 'ro',
3548             );
3549              
3550              
3551             =head4 java_method
3552              
3553              
3554             =cut
3555              
3556             has java_method =>
3557             (is => 'ro',
3558             );
3559              
3560              
3561             =head4 java_stack_trace_element
3562              
3563              
3564             =cut
3565              
3566             has java_stack_trace_element =>
3567             (is => 'ro',
3568             );
3569              
3570              
3571             =head4 location
3572              
3573              
3574             =cut
3575              
3576             has location =>
3577             (is => 'ro',
3578             );
3579              
3580              
3581             }
3582              
3583             package Cucumber::Messages::JavaMethod {
3584             $Cucumber::Messages::JavaMethod::VERSION = '34.0.1';
3585             =head2 Cucumber::Messages::JavaMethod
3586              
3587             =head3 DESCRIPTION
3588              
3589             Represents the JavaMethod message in Cucumber's
3590             L.
3591              
3592              
3593              
3594             =head3 ATTRIBUTES
3595              
3596             =cut
3597              
3598 3     3   17 use Moo;
  3         6  
  3         10  
3599             extends 'Cucumber::Messages::Message';
3600              
3601 3     3   964 use Scalar::Util qw( blessed );
  3         4  
  3         567  
3602              
3603             my %types = (
3604             class_name => 'string',
3605             method_name => 'string',
3606             method_parameter_types => '[]string',
3607             );
3608              
3609             # This is a work-around for the fact that Moo doesn't have introspection
3610             # and Perl doesn't have boolean values...
3611             sub _types {
3612 0     0     return \%types;
3613             }
3614              
3615              
3616              
3617             =head4 class_name
3618              
3619              
3620             =cut
3621              
3622             has class_name =>
3623             (is => 'ro',
3624             required => 1,
3625             default => sub { '' },
3626             );
3627              
3628              
3629             =head4 method_name
3630              
3631              
3632             =cut
3633              
3634             has method_name =>
3635             (is => 'ro',
3636             required => 1,
3637             default => sub { '' },
3638             );
3639              
3640              
3641             =head4 method_parameter_types
3642              
3643              
3644             =cut
3645              
3646             has method_parameter_types =>
3647             (is => 'ro',
3648             required => 1,
3649             default => sub { [] },
3650             );
3651              
3652              
3653             }
3654              
3655             package Cucumber::Messages::JavaStackTraceElement {
3656             $Cucumber::Messages::JavaStackTraceElement::VERSION = '34.0.1';
3657             =head2 Cucumber::Messages::JavaStackTraceElement
3658              
3659             =head3 DESCRIPTION
3660              
3661             Represents the JavaStackTraceElement message in Cucumber's
3662             L.
3663              
3664              
3665              
3666             =head3 ATTRIBUTES
3667              
3668             =cut
3669              
3670 3     3   17 use Moo;
  3         4  
  3         9  
3671             extends 'Cucumber::Messages::Message';
3672              
3673 3     3   861 use Scalar::Util qw( blessed );
  3         9  
  3         541  
3674              
3675             my %types = (
3676             class_name => 'string',
3677             file_name => 'string',
3678             method_name => 'string',
3679             );
3680              
3681             # This is a work-around for the fact that Moo doesn't have introspection
3682             # and Perl doesn't have boolean values...
3683             sub _types {
3684 0     0     return \%types;
3685             }
3686              
3687              
3688              
3689             =head4 class_name
3690              
3691              
3692             =cut
3693              
3694             has class_name =>
3695             (is => 'ro',
3696             required => 1,
3697             default => sub { '' },
3698             );
3699              
3700              
3701             =head4 file_name
3702              
3703              
3704             =cut
3705              
3706             has file_name =>
3707             (is => 'ro',
3708             required => 1,
3709             default => sub { '' },
3710             );
3711              
3712              
3713             =head4 method_name
3714              
3715              
3716             =cut
3717              
3718             has method_name =>
3719             (is => 'ro',
3720             required => 1,
3721             default => sub { '' },
3722             );
3723              
3724              
3725             }
3726              
3727             package Cucumber::Messages::StepDefinition {
3728             $Cucumber::Messages::StepDefinition::VERSION = '34.0.1';
3729             =head2 Cucumber::Messages::StepDefinition
3730              
3731             =head3 DESCRIPTION
3732              
3733             Represents the StepDefinition message in Cucumber's
3734             L.
3735              
3736              
3737              
3738             =head3 ATTRIBUTES
3739              
3740             =cut
3741              
3742 3     3   17 use Moo;
  3         6  
  3         16  
3743             extends 'Cucumber::Messages::Message';
3744              
3745 3     3   849 use Scalar::Util qw( blessed );
  3         5  
  3         558  
3746              
3747             my %types = (
3748             id => 'string',
3749             pattern => 'Cucumber::Messages::StepDefinitionPattern',
3750             source_reference => 'Cucumber::Messages::SourceReference',
3751             );
3752              
3753             # This is a work-around for the fact that Moo doesn't have introspection
3754             # and Perl doesn't have boolean values...
3755             sub _types {
3756 0     0     return \%types;
3757             }
3758              
3759              
3760              
3761             =head4 id
3762              
3763              
3764             =cut
3765              
3766             has id =>
3767             (is => 'ro',
3768             required => 1,
3769             default => sub { '' },
3770             );
3771              
3772              
3773             =head4 pattern
3774              
3775              
3776             =cut
3777              
3778             has pattern =>
3779             (is => 'ro',
3780             required => 1,
3781             default => sub { Cucumber::Messages::StepDefinitionPattern->new() },
3782             );
3783              
3784              
3785             =head4 source_reference
3786              
3787              
3788             =cut
3789              
3790             has source_reference =>
3791             (is => 'ro',
3792             required => 1,
3793             default => sub { Cucumber::Messages::SourceReference->new() },
3794             );
3795              
3796              
3797             }
3798              
3799             package Cucumber::Messages::StepDefinitionPattern {
3800             $Cucumber::Messages::StepDefinitionPattern::VERSION = '34.0.1';
3801             =head2 Cucumber::Messages::StepDefinitionPattern
3802              
3803             =head3 DESCRIPTION
3804              
3805             Represents the StepDefinitionPattern message in Cucumber's
3806             L.
3807              
3808              
3809              
3810             =head3 ATTRIBUTES
3811              
3812             =cut
3813              
3814 3     3   15 use Moo;
  3         4  
  3         9  
3815             extends 'Cucumber::Messages::Message';
3816              
3817 3     3   859 use Scalar::Util qw( blessed );
  3         5  
  3         370  
3818              
3819             my %types = (
3820             source => 'string',
3821             type => '',
3822             );
3823              
3824             # This is a work-around for the fact that Moo doesn't have introspection
3825             # and Perl doesn't have boolean values...
3826             sub _types {
3827 0     0     return \%types;
3828             }
3829              
3830              
3831              
3832             =head4 source
3833              
3834              
3835             =cut
3836              
3837             has source =>
3838             (is => 'ro',
3839             required => 1,
3840             default => sub { '' },
3841             );
3842              
3843              
3844             =head4 type
3845              
3846              
3847              
3848             Available constants for valid values of this field:
3849              
3850             =over
3851              
3852             =item * TYPE_CUCUMBER_EXPRESSION
3853              
3854             =item * TYPE_REGULAR_EXPRESSION
3855              
3856             =back
3857              
3858             =cut
3859              
3860              
3861             use constant {
3862 3         325 TYPE_CUCUMBER_EXPRESSION => 'CUCUMBER_EXPRESSION',
3863             TYPE_REGULAR_EXPRESSION => 'REGULAR_EXPRESSION',
3864 3     3   16 };
  3         8  
3865              
3866             has type =>
3867             (is => 'ro',
3868             required => 1,
3869             default => sub { TYPE_CUCUMBER_EXPRESSION },
3870             );
3871              
3872              
3873             }
3874              
3875             package Cucumber::Messages::Suggestion {
3876             $Cucumber::Messages::Suggestion::VERSION = '34.0.1';
3877             =head2 Cucumber::Messages::Suggestion
3878              
3879             =head3 DESCRIPTION
3880              
3881             Represents the Suggestion message in Cucumber's
3882             L.
3883              
3884             A suggested fragment of code to implement an undefined step
3885              
3886             =head3 ATTRIBUTES
3887              
3888             =cut
3889              
3890 3     3   15 use Moo;
  3         3  
  3         17  
3891             extends 'Cucumber::Messages::Message';
3892              
3893 3     3   898 use Scalar::Util qw( blessed );
  3         4  
  3         627  
3894              
3895             my %types = (
3896             id => 'string',
3897             pickle_step_id => 'string',
3898             snippets => '[]Cucumber::Messages::Snippet',
3899             );
3900              
3901             # This is a work-around for the fact that Moo doesn't have introspection
3902             # and Perl doesn't have boolean values...
3903             sub _types {
3904 0     0     return \%types;
3905             }
3906              
3907              
3908              
3909             =head4 id
3910              
3911             A unique id for this suggestion
3912             =cut
3913              
3914             has id =>
3915             (is => 'ro',
3916             required => 1,
3917             default => sub { '' },
3918             );
3919              
3920              
3921             =head4 pickle_step_id
3922              
3923             The ID of the `PickleStep` this `Suggestion` was created for.
3924             =cut
3925              
3926             has pickle_step_id =>
3927             (is => 'ro',
3928             required => 1,
3929             default => sub { '' },
3930             );
3931              
3932              
3933             =head4 snippets
3934              
3935             A collection of code snippets that could implement the undefined step
3936             =cut
3937              
3938             has snippets =>
3939             (is => 'ro',
3940             required => 1,
3941             default => sub { [] },
3942             );
3943              
3944              
3945             }
3946              
3947             package Cucumber::Messages::Snippet {
3948             $Cucumber::Messages::Snippet::VERSION = '34.0.1';
3949             =head2 Cucumber::Messages::Snippet
3950              
3951             =head3 DESCRIPTION
3952              
3953             Represents the Snippet message in Cucumber's
3954             L.
3955              
3956              
3957              
3958             =head3 ATTRIBUTES
3959              
3960             =cut
3961              
3962 3     3   19 use Moo;
  3         3  
  3         11  
3963             extends 'Cucumber::Messages::Message';
3964              
3965 3     3   805 use Scalar::Util qw( blessed );
  3         14  
  3         400  
3966              
3967             my %types = (
3968             language => 'string',
3969             code => 'string',
3970             );
3971              
3972             # This is a work-around for the fact that Moo doesn't have introspection
3973             # and Perl doesn't have boolean values...
3974             sub _types {
3975 0     0     return \%types;
3976             }
3977              
3978              
3979              
3980             =head4 language
3981              
3982             The programming language of the code.
3983              
3984             This must be formatted as an all lowercase identifier such that syntax highlighters like [Prism](https://prismjs.com/#supported-languages) or [Highlight.js](https://github.com/highlightjs/highlight.js/blob/main/SUPPORTED_LANGUAGES.md) can recognize it.
3985             For example: `cpp`, `cs`, `go`, `java`, `javascript`, `php`, `python`, `ruby`, `scala`.
3986             =cut
3987              
3988             has language =>
3989             (is => 'ro',
3990             required => 1,
3991             default => sub { '' },
3992             );
3993              
3994              
3995             =head4 code
3996              
3997             A snippet of code
3998             =cut
3999              
4000             has code =>
4001             (is => 'ro',
4002             required => 1,
4003             default => sub { '' },
4004             );
4005              
4006              
4007             }
4008              
4009             package Cucumber::Messages::TestCase {
4010             $Cucumber::Messages::TestCase::VERSION = '34.0.1';
4011             =head2 Cucumber::Messages::TestCase
4012              
4013             =head3 DESCRIPTION
4014              
4015             Represents the TestCase message in Cucumber's
4016             L.
4017              
4018             A `TestCase` contains a sequence of `TestStep`s.
4019              
4020             =head3 ATTRIBUTES
4021              
4022             =cut
4023              
4024 3     3   13 use Moo;
  3         4  
  3         9  
4025             extends 'Cucumber::Messages::Message';
4026              
4027 3     3   807 use Scalar::Util qw( blessed );
  3         10  
  3         587  
4028              
4029             my %types = (
4030             id => 'string',
4031             pickle_id => 'string',
4032             test_steps => '[]Cucumber::Messages::TestStep',
4033             test_run_started_id => 'string',
4034             );
4035              
4036             # This is a work-around for the fact that Moo doesn't have introspection
4037             # and Perl doesn't have boolean values...
4038             sub _types {
4039 0     0     return \%types;
4040             }
4041              
4042              
4043              
4044             =head4 id
4045              
4046              
4047             =cut
4048              
4049             has id =>
4050             (is => 'ro',
4051             required => 1,
4052             default => sub { '' },
4053             );
4054              
4055              
4056             =head4 pickle_id
4057              
4058             The ID of the `Pickle` this `TestCase` is derived from.
4059             =cut
4060              
4061             has pickle_id =>
4062             (is => 'ro',
4063             required => 1,
4064             default => sub { '' },
4065             );
4066              
4067              
4068             =head4 test_steps
4069              
4070              
4071             =cut
4072              
4073             has test_steps =>
4074             (is => 'ro',
4075             required => 1,
4076             default => sub { [] },
4077             );
4078              
4079              
4080             =head4 test_run_started_id
4081              
4082             Identifier for the test run that this test case belongs to
4083             =cut
4084              
4085             has test_run_started_id =>
4086             (is => 'ro',
4087             );
4088              
4089              
4090             }
4091              
4092             package Cucumber::Messages::Group {
4093             $Cucumber::Messages::Group::VERSION = '34.0.1';
4094             =head2 Cucumber::Messages::Group
4095              
4096             =head3 DESCRIPTION
4097              
4098             Represents the Group message in Cucumber's
4099             L.
4100              
4101              
4102              
4103             =head3 ATTRIBUTES
4104              
4105             =cut
4106              
4107 3     3   20 use Moo;
  3         11  
  3         12  
4108             extends 'Cucumber::Messages::Message';
4109              
4110 3     3   977 use Scalar::Util qw( blessed );
  3         6  
  3         627  
4111              
4112             my %types = (
4113             children => '[]Cucumber::Messages::Group',
4114             start => 'number',
4115             value => 'string',
4116             );
4117              
4118             # This is a work-around for the fact that Moo doesn't have introspection
4119             # and Perl doesn't have boolean values...
4120             sub _types {
4121 0     0     return \%types;
4122             }
4123              
4124              
4125              
4126             =head4 children
4127              
4128             The nested capture groups of an argument.
4129             Absent if the group has no nested capture groups.
4130             =cut
4131              
4132             has children =>
4133             (is => 'ro',
4134             );
4135              
4136              
4137             =head4 start
4138              
4139              
4140             =cut
4141              
4142             has start =>
4143             (is => 'ro',
4144             );
4145              
4146              
4147             =head4 value
4148              
4149              
4150             =cut
4151              
4152             has value =>
4153             (is => 'ro',
4154             );
4155              
4156              
4157             }
4158              
4159             package Cucumber::Messages::StepMatchArgument {
4160             $Cucumber::Messages::StepMatchArgument::VERSION = '34.0.1';
4161             =head2 Cucumber::Messages::StepMatchArgument
4162              
4163             =head3 DESCRIPTION
4164              
4165             Represents the StepMatchArgument message in Cucumber's
4166             L.
4167              
4168             Represents a single argument extracted from a step match and passed to a step definition.
4169             This is used for the following purposes:
4170             - Construct an argument to pass to a step definition (possibly through a parameter type transform)
4171             - Highlight the matched parameter in rich formatters such as the HTML formatter
4172              
4173             This message closely matches the `Argument` class in the `cucumber-expressions` library.
4174              
4175             =head3 ATTRIBUTES
4176              
4177             =cut
4178              
4179 3     3   34 use Moo;
  3         6  
  3         14  
4180             extends 'Cucumber::Messages::Message';
4181              
4182 3     3   907 use Scalar::Util qw( blessed );
  3         5  
  3         469  
4183              
4184             my %types = (
4185             group => 'Cucumber::Messages::Group',
4186             parameter_type_name => 'string',
4187             );
4188              
4189             # This is a work-around for the fact that Moo doesn't have introspection
4190             # and Perl doesn't have boolean values...
4191             sub _types {
4192 0     0     return \%types;
4193             }
4194              
4195              
4196              
4197             =head4 group
4198              
4199             Represents the outermost capture group of an argument. This message closely matches the
4200             `Group` class in the `cucumber-expressions` library.
4201             =cut
4202              
4203             has group =>
4204             (is => 'ro',
4205             required => 1,
4206             default => sub { Cucumber::Messages::Group->new() },
4207             );
4208              
4209              
4210             =head4 parameter_type_name
4211              
4212              
4213             =cut
4214              
4215             has parameter_type_name =>
4216             (is => 'ro',
4217             );
4218              
4219              
4220             }
4221              
4222             package Cucumber::Messages::StepMatchArgumentsList {
4223             $Cucumber::Messages::StepMatchArgumentsList::VERSION = '34.0.1';
4224             =head2 Cucumber::Messages::StepMatchArgumentsList
4225              
4226             =head3 DESCRIPTION
4227              
4228             Represents the StepMatchArgumentsList message in Cucumber's
4229             L.
4230              
4231              
4232              
4233             =head3 ATTRIBUTES
4234              
4235             =cut
4236              
4237 3     3   15 use Moo;
  3         5  
  3         10  
4238             extends 'Cucumber::Messages::Message';
4239              
4240 3     3   946 use Scalar::Util qw( blessed );
  3         4  
  3         417  
4241              
4242             my %types = (
4243             step_match_arguments => '[]Cucumber::Messages::StepMatchArgument',
4244             );
4245              
4246             # This is a work-around for the fact that Moo doesn't have introspection
4247             # and Perl doesn't have boolean values...
4248             sub _types {
4249 0     0     return \%types;
4250             }
4251              
4252              
4253              
4254             =head4 step_match_arguments
4255              
4256              
4257             =cut
4258              
4259             has step_match_arguments =>
4260             (is => 'ro',
4261             required => 1,
4262             default => sub { [] },
4263             );
4264              
4265              
4266             }
4267              
4268             package Cucumber::Messages::TestStep {
4269             $Cucumber::Messages::TestStep::VERSION = '34.0.1';
4270             =head2 Cucumber::Messages::TestStep
4271              
4272             =head3 DESCRIPTION
4273              
4274             Represents the TestStep message in Cucumber's
4275             L.
4276              
4277             A `TestStep` is derived from either a `PickleStep` combined with a `StepDefinition`, or from a `Hook`.
4278              
4279             When derived from a PickleStep:
4280             * For `UNDEFINED` steps `stepDefinitionIds` and `stepMatchArgumentsLists` will be empty.
4281             * For `AMBIGUOUS` steps, there will be multiple entries in `stepDefinitionIds` and `stepMatchArgumentsLists`. The first entry in the stepMatchArgumentsLists holds the list of arguments for the first matching step definition, the second entry for the second, etc
4282              
4283             =head3 ATTRIBUTES
4284              
4285             =cut
4286              
4287 3     3   16 use Moo;
  3         4  
  3         15  
4288             extends 'Cucumber::Messages::Message';
4289              
4290 3     3   769 use Scalar::Util qw( blessed );
  3         11  
  3         452  
4291              
4292             my %types = (
4293             hook_id => 'string',
4294             id => 'string',
4295             pickle_step_id => 'string',
4296             step_definition_ids => '[]string',
4297             step_match_arguments_lists => '[]Cucumber::Messages::StepMatchArgumentsList',
4298             );
4299              
4300             # This is a work-around for the fact that Moo doesn't have introspection
4301             # and Perl doesn't have boolean values...
4302             sub _types {
4303 0     0     return \%types;
4304             }
4305              
4306              
4307              
4308             =head4 hook_id
4309              
4310             Pointer to the `Hook` (if derived from a Hook)
4311             =cut
4312              
4313             has hook_id =>
4314             (is => 'ro',
4315             );
4316              
4317              
4318             =head4 id
4319              
4320              
4321             =cut
4322              
4323             has id =>
4324             (is => 'ro',
4325             required => 1,
4326             default => sub { '' },
4327             );
4328              
4329              
4330             =head4 pickle_step_id
4331              
4332             Pointer to the `PickleStep` (if derived from a `PickleStep`)
4333             =cut
4334              
4335             has pickle_step_id =>
4336             (is => 'ro',
4337             );
4338              
4339              
4340             =head4 step_definition_ids
4341              
4342             Pointer to all the matching `StepDefinition`s (if derived from a `PickleStep`).
4343              
4344             Each element represents a matching step definition.
4345             =cut
4346              
4347             has step_definition_ids =>
4348             (is => 'ro',
4349             );
4350              
4351              
4352             =head4 step_match_arguments_lists
4353              
4354             A list of list of StepMatchArgument (if derived from a `PickleStep`).
4355              
4356             Each element represents the arguments for a matching step definition.
4357             =cut
4358              
4359             has step_match_arguments_lists =>
4360             (is => 'ro',
4361             );
4362              
4363              
4364             }
4365              
4366             package Cucumber::Messages::TestCaseFinished {
4367             $Cucumber::Messages::TestCaseFinished::VERSION = '34.0.1';
4368             =head2 Cucumber::Messages::TestCaseFinished
4369              
4370             =head3 DESCRIPTION
4371              
4372             Represents the TestCaseFinished message in Cucumber's
4373             L.
4374              
4375              
4376              
4377             =head3 ATTRIBUTES
4378              
4379             =cut
4380              
4381 3     3   15 use Moo;
  3         4  
  3         9  
4382             extends 'Cucumber::Messages::Message';
4383              
4384 3     3   812 use Scalar::Util qw( blessed );
  3         3  
  3         569  
4385              
4386             my %types = (
4387             test_case_started_id => 'string',
4388             timestamp => 'Cucumber::Messages::Timestamp',
4389             will_be_retried => 'boolean',
4390             );
4391              
4392             # This is a work-around for the fact that Moo doesn't have introspection
4393             # and Perl doesn't have boolean values...
4394             sub _types {
4395 0     0     return \%types;
4396             }
4397              
4398              
4399              
4400             =head4 test_case_started_id
4401              
4402              
4403             =cut
4404              
4405             has test_case_started_id =>
4406             (is => 'ro',
4407             required => 1,
4408             default => sub { '' },
4409             );
4410              
4411              
4412             =head4 timestamp
4413              
4414              
4415             =cut
4416              
4417             has timestamp =>
4418             (is => 'ro',
4419             required => 1,
4420             default => sub { Cucumber::Messages::Timestamp->new() },
4421             );
4422              
4423              
4424             =head4 will_be_retried
4425              
4426              
4427             =cut
4428              
4429             has will_be_retried =>
4430             (is => 'ro',
4431             required => 1,
4432             default => sub { '' },
4433             );
4434              
4435              
4436             }
4437              
4438             package Cucumber::Messages::TestCaseStarted {
4439             $Cucumber::Messages::TestCaseStarted::VERSION = '34.0.1';
4440             =head2 Cucumber::Messages::TestCaseStarted
4441              
4442             =head3 DESCRIPTION
4443              
4444             Represents the TestCaseStarted message in Cucumber's
4445             L.
4446              
4447              
4448              
4449             =head3 ATTRIBUTES
4450              
4451             =cut
4452              
4453 3     3   31 use Moo;
  3         3  
  3         159  
4454             extends 'Cucumber::Messages::Message';
4455              
4456 3     3   860 use Scalar::Util qw( blessed );
  3         4  
  3         612  
4457              
4458             my %types = (
4459             attempt => 'number',
4460             id => 'string',
4461             test_case_id => 'string',
4462             worker_id => 'string',
4463             timestamp => 'Cucumber::Messages::Timestamp',
4464             );
4465              
4466             # This is a work-around for the fact that Moo doesn't have introspection
4467             # and Perl doesn't have boolean values...
4468             sub _types {
4469 0     0     return \%types;
4470             }
4471              
4472              
4473              
4474             =head4 attempt
4475              
4476             The first attempt should have value 0, and for each retry the value
4477             should increase by 1.
4478             =cut
4479              
4480             has attempt =>
4481             (is => 'ro',
4482             required => 1,
4483             default => sub { 0 },
4484             );
4485              
4486              
4487             =head4 id
4488              
4489             Because a `TestCase` can be run multiple times (in case of a retry),
4490             we use this field to group messages relating to the same attempt.
4491             =cut
4492              
4493             has id =>
4494             (is => 'ro',
4495             required => 1,
4496             default => sub { '' },
4497             );
4498              
4499              
4500             =head4 test_case_id
4501              
4502              
4503             =cut
4504              
4505             has test_case_id =>
4506             (is => 'ro',
4507             required => 1,
4508             default => sub { '' },
4509             );
4510              
4511              
4512             =head4 worker_id
4513              
4514             An identifier for the worker process running this test case, if test cases are being run in parallel. The identifier will be unique per worker, but no particular format is defined - it could be an index, uuid, machine name etc - and as such should be assumed that it's not human readable.
4515             =cut
4516              
4517             has worker_id =>
4518             (is => 'ro',
4519             );
4520              
4521              
4522             =head4 timestamp
4523              
4524              
4525             =cut
4526              
4527             has timestamp =>
4528             (is => 'ro',
4529             required => 1,
4530             default => sub { Cucumber::Messages::Timestamp->new() },
4531             );
4532              
4533              
4534             }
4535              
4536             package Cucumber::Messages::TestRunFinished {
4537             $Cucumber::Messages::TestRunFinished::VERSION = '34.0.1';
4538             =head2 Cucumber::Messages::TestRunFinished
4539              
4540             =head3 DESCRIPTION
4541              
4542             Represents the TestRunFinished message in Cucumber's
4543             L.
4544              
4545              
4546              
4547             =head3 ATTRIBUTES
4548              
4549             =cut
4550              
4551 3     3   34 use Moo;
  3         5  
  3         8  
4552             extends 'Cucumber::Messages::Message';
4553              
4554 3     3   793 use Scalar::Util qw( blessed );
  3         6  
  3         670  
4555              
4556             my %types = (
4557             message => 'string',
4558             success => 'boolean',
4559             timestamp => 'Cucumber::Messages::Timestamp',
4560             exception => 'Cucumber::Messages::Exception',
4561             test_run_started_id => 'string',
4562             );
4563              
4564             # This is a work-around for the fact that Moo doesn't have introspection
4565             # and Perl doesn't have boolean values...
4566             sub _types {
4567 0     0     return \%types;
4568             }
4569              
4570              
4571              
4572             =head4 message
4573              
4574             An informative message about the test run. Typically additional information about failure, but not necessarily.
4575             =cut
4576              
4577             has message =>
4578             (is => 'ro',
4579             );
4580              
4581              
4582             =head4 success
4583              
4584             A test run is successful if all steps are either passed or skipped, all before/after hooks passed and no other exceptions where thrown.
4585             =cut
4586              
4587             has success =>
4588             (is => 'ro',
4589             required => 1,
4590             default => sub { '' },
4591             );
4592              
4593              
4594             =head4 timestamp
4595              
4596             Timestamp when the TestRun is finished
4597             =cut
4598              
4599             has timestamp =>
4600             (is => 'ro',
4601             required => 1,
4602             default => sub { Cucumber::Messages::Timestamp->new() },
4603             );
4604              
4605              
4606             =head4 exception
4607              
4608             Any exception thrown during the test run, if any. Does not include exceptions thrown while executing steps.
4609             =cut
4610              
4611             has exception =>
4612             (is => 'ro',
4613             );
4614              
4615              
4616             =head4 test_run_started_id
4617              
4618              
4619             =cut
4620              
4621             has test_run_started_id =>
4622             (is => 'ro',
4623             );
4624              
4625              
4626             }
4627              
4628             package Cucumber::Messages::TestRunHookFinished {
4629             $Cucumber::Messages::TestRunHookFinished::VERSION = '34.0.1';
4630             =head2 Cucumber::Messages::TestRunHookFinished
4631              
4632             =head3 DESCRIPTION
4633              
4634             Represents the TestRunHookFinished message in Cucumber's
4635             L.
4636              
4637              
4638              
4639             =head3 ATTRIBUTES
4640              
4641             =cut
4642              
4643 3     3   18 use Moo;
  3         4  
  3         19  
4644             extends 'Cucumber::Messages::Message';
4645              
4646 3     3   782 use Scalar::Util qw( blessed );
  3         5  
  3         521  
4647              
4648             my %types = (
4649             test_run_hook_started_id => 'string',
4650             result => 'Cucumber::Messages::TestStepResult',
4651             timestamp => 'Cucumber::Messages::Timestamp',
4652             );
4653              
4654             # This is a work-around for the fact that Moo doesn't have introspection
4655             # and Perl doesn't have boolean values...
4656             sub _types {
4657 0     0     return \%types;
4658             }
4659              
4660              
4661              
4662             =head4 test_run_hook_started_id
4663              
4664             Identifier for the hook execution that has finished
4665             =cut
4666              
4667             has test_run_hook_started_id =>
4668             (is => 'ro',
4669             required => 1,
4670             default => sub { '' },
4671             );
4672              
4673              
4674             =head4 result
4675              
4676              
4677             =cut
4678              
4679             has result =>
4680             (is => 'ro',
4681             required => 1,
4682             default => sub { Cucumber::Messages::TestStepResult->new() },
4683             );
4684              
4685              
4686             =head4 timestamp
4687              
4688              
4689             =cut
4690              
4691             has timestamp =>
4692             (is => 'ro',
4693             required => 1,
4694             default => sub { Cucumber::Messages::Timestamp->new() },
4695             );
4696              
4697              
4698             }
4699              
4700             package Cucumber::Messages::TestRunHookStarted {
4701             $Cucumber::Messages::TestRunHookStarted::VERSION = '34.0.1';
4702             =head2 Cucumber::Messages::TestRunHookStarted
4703              
4704             =head3 DESCRIPTION
4705              
4706             Represents the TestRunHookStarted message in Cucumber's
4707             L.
4708              
4709              
4710              
4711             =head3 ATTRIBUTES
4712              
4713             =cut
4714              
4715 3     3   14 use Moo;
  3         6  
  3         21  
4716             extends 'Cucumber::Messages::Message';
4717              
4718 3     3   773 use Scalar::Util qw( blessed );
  3         12  
  3         627  
4719              
4720             my %types = (
4721             id => 'string',
4722             test_run_started_id => 'string',
4723             hook_id => 'string',
4724             worker_id => 'string',
4725             timestamp => 'Cucumber::Messages::Timestamp',
4726             );
4727              
4728             # This is a work-around for the fact that Moo doesn't have introspection
4729             # and Perl doesn't have boolean values...
4730             sub _types {
4731 0     0     return \%types;
4732             }
4733              
4734              
4735              
4736             =head4 id
4737              
4738             Unique identifier for this hook execution
4739             =cut
4740              
4741             has id =>
4742             (is => 'ro',
4743             required => 1,
4744             default => sub { '' },
4745             );
4746              
4747              
4748             =head4 test_run_started_id
4749              
4750             Identifier for the test run that this hook execution belongs to
4751             =cut
4752              
4753             has test_run_started_id =>
4754             (is => 'ro',
4755             required => 1,
4756             default => sub { '' },
4757             );
4758              
4759              
4760             =head4 hook_id
4761              
4762             Identifier for the hook that will be executed
4763             =cut
4764              
4765             has hook_id =>
4766             (is => 'ro',
4767             required => 1,
4768             default => sub { '' },
4769             );
4770              
4771              
4772             =head4 worker_id
4773              
4774             An identifier for the worker process running this hook, if parallel workers are in use. The identifier will be unique per worker, but no particular format is defined - it could be an index, uuid, machine name etc - and as such should be assumed that it's not human readable.
4775             =cut
4776              
4777             has worker_id =>
4778             (is => 'ro',
4779             );
4780              
4781              
4782             =head4 timestamp
4783              
4784              
4785             =cut
4786              
4787             has timestamp =>
4788             (is => 'ro',
4789             required => 1,
4790             default => sub { Cucumber::Messages::Timestamp->new() },
4791             );
4792              
4793              
4794             }
4795              
4796             package Cucumber::Messages::TestRunStarted {
4797             $Cucumber::Messages::TestRunStarted::VERSION = '34.0.1';
4798             =head2 Cucumber::Messages::TestRunStarted
4799              
4800             =head3 DESCRIPTION
4801              
4802             Represents the TestRunStarted message in Cucumber's
4803             L.
4804              
4805              
4806              
4807             =head3 ATTRIBUTES
4808              
4809             =cut
4810              
4811 3     3   33 use Moo;
  3         4  
  3         11  
4812             extends 'Cucumber::Messages::Message';
4813              
4814 3     3   784 use Scalar::Util qw( blessed );
  3         4  
  3         416  
4815              
4816             my %types = (
4817             timestamp => 'Cucumber::Messages::Timestamp',
4818             id => 'string',
4819             );
4820              
4821             # This is a work-around for the fact that Moo doesn't have introspection
4822             # and Perl doesn't have boolean values...
4823             sub _types {
4824 0     0     return \%types;
4825             }
4826              
4827              
4828              
4829             =head4 timestamp
4830              
4831              
4832             =cut
4833              
4834             has timestamp =>
4835             (is => 'ro',
4836             required => 1,
4837             default => sub { Cucumber::Messages::Timestamp->new() },
4838             );
4839              
4840              
4841             =head4 id
4842              
4843              
4844             =cut
4845              
4846             has id =>
4847             (is => 'ro',
4848             );
4849              
4850              
4851             }
4852              
4853             package Cucumber::Messages::TestStepFinished {
4854             $Cucumber::Messages::TestStepFinished::VERSION = '34.0.1';
4855             =head2 Cucumber::Messages::TestStepFinished
4856              
4857             =head3 DESCRIPTION
4858              
4859             Represents the TestStepFinished message in Cucumber's
4860             L.
4861              
4862              
4863              
4864             =head3 ATTRIBUTES
4865              
4866             =cut
4867              
4868 3     3   15 use Moo;
  3         3  
  3         8  
4869             extends 'Cucumber::Messages::Message';
4870              
4871 3     3   780 use Scalar::Util qw( blessed );
  3         5  
  3         539  
4872              
4873             my %types = (
4874             test_case_started_id => 'string',
4875             test_step_id => 'string',
4876             test_step_result => 'Cucumber::Messages::TestStepResult',
4877             timestamp => 'Cucumber::Messages::Timestamp',
4878             );
4879              
4880             # This is a work-around for the fact that Moo doesn't have introspection
4881             # and Perl doesn't have boolean values...
4882             sub _types {
4883 0     0     return \%types;
4884             }
4885              
4886              
4887              
4888             =head4 test_case_started_id
4889              
4890              
4891             =cut
4892              
4893             has test_case_started_id =>
4894             (is => 'ro',
4895             required => 1,
4896             default => sub { '' },
4897             );
4898              
4899              
4900             =head4 test_step_id
4901              
4902              
4903             =cut
4904              
4905             has test_step_id =>
4906             (is => 'ro',
4907             required => 1,
4908             default => sub { '' },
4909             );
4910              
4911              
4912             =head4 test_step_result
4913              
4914              
4915             =cut
4916              
4917             has test_step_result =>
4918             (is => 'ro',
4919             required => 1,
4920             default => sub { Cucumber::Messages::TestStepResult->new() },
4921             );
4922              
4923              
4924             =head4 timestamp
4925              
4926              
4927             =cut
4928              
4929             has timestamp =>
4930             (is => 'ro',
4931             required => 1,
4932             default => sub { Cucumber::Messages::Timestamp->new() },
4933             );
4934              
4935              
4936             }
4937              
4938             package Cucumber::Messages::TestStepResult {
4939             $Cucumber::Messages::TestStepResult::VERSION = '34.0.1';
4940             =head2 Cucumber::Messages::TestStepResult
4941              
4942             =head3 DESCRIPTION
4943              
4944             Represents the TestStepResult message in Cucumber's
4945             L.
4946              
4947              
4948              
4949             =head3 ATTRIBUTES
4950              
4951             =cut
4952              
4953 3     3   14 use Moo;
  3         5  
  3         9  
4954             extends 'Cucumber::Messages::Message';
4955              
4956 3     3   882 use Scalar::Util qw( blessed );
  3         9  
  3         463  
4957              
4958             my %types = (
4959             duration => 'Cucumber::Messages::Duration',
4960             message => 'string',
4961             status => '',
4962             exception => 'Cucumber::Messages::Exception',
4963             );
4964              
4965             # This is a work-around for the fact that Moo doesn't have introspection
4966             # and Perl doesn't have boolean values...
4967             sub _types {
4968 0     0     return \%types;
4969             }
4970              
4971              
4972              
4973             =head4 duration
4974              
4975              
4976             =cut
4977              
4978             has duration =>
4979             (is => 'ro',
4980             required => 1,
4981             default => sub { Cucumber::Messages::Duration->new() },
4982             );
4983              
4984              
4985             =head4 message
4986              
4987             An arbitrary bit of information that explains this result. If there was an exception, this should include a stringified representation of it including type, message and stack trace (the exact format will vary by platform).
4988             =cut
4989              
4990             has message =>
4991             (is => 'ro',
4992             );
4993              
4994              
4995             =head4 status
4996              
4997              
4998              
4999             Available constants for valid values of this field:
5000              
5001             =over
5002              
5003             =item * STATUS_UNKNOWN
5004              
5005             =item * STATUS_PASSED
5006              
5007             =item * STATUS_SKIPPED
5008              
5009             =item * STATUS_PENDING
5010              
5011             =item * STATUS_UNDEFINED
5012              
5013             =item * STATUS_AMBIGUOUS
5014              
5015             =item * STATUS_FAILED
5016              
5017             =back
5018              
5019             =cut
5020              
5021              
5022             use constant {
5023 3         562 STATUS_UNKNOWN => 'UNKNOWN',
5024             STATUS_PASSED => 'PASSED',
5025             STATUS_SKIPPED => 'SKIPPED',
5026             STATUS_PENDING => 'PENDING',
5027             STATUS_UNDEFINED => 'UNDEFINED',
5028             STATUS_AMBIGUOUS => 'AMBIGUOUS',
5029             STATUS_FAILED => 'FAILED',
5030 3     3   15 };
  3         3  
5031              
5032             has status =>
5033             (is => 'ro',
5034             required => 1,
5035             default => sub { STATUS_UNKNOWN },
5036             );
5037              
5038              
5039             =head4 exception
5040              
5041             Exception thrown while executing this step, if any.
5042             =cut
5043              
5044             has exception =>
5045             (is => 'ro',
5046             );
5047              
5048              
5049             }
5050              
5051             package Cucumber::Messages::TestStepStarted {
5052             $Cucumber::Messages::TestStepStarted::VERSION = '34.0.1';
5053             =head2 Cucumber::Messages::TestStepStarted
5054              
5055             =head3 DESCRIPTION
5056              
5057             Represents the TestStepStarted message in Cucumber's
5058             L.
5059              
5060              
5061              
5062             =head3 ATTRIBUTES
5063              
5064             =cut
5065              
5066 3     3   16 use Moo;
  3         4  
  3         10  
5067             extends 'Cucumber::Messages::Message';
5068              
5069 3     3   792 use Scalar::Util qw( blessed );
  3         4  
  3         541  
5070              
5071             my %types = (
5072             test_case_started_id => 'string',
5073             test_step_id => 'string',
5074             timestamp => 'Cucumber::Messages::Timestamp',
5075             );
5076              
5077             # This is a work-around for the fact that Moo doesn't have introspection
5078             # and Perl doesn't have boolean values...
5079             sub _types {
5080 0     0     return \%types;
5081             }
5082              
5083              
5084              
5085             =head4 test_case_started_id
5086              
5087              
5088             =cut
5089              
5090             has test_case_started_id =>
5091             (is => 'ro',
5092             required => 1,
5093             default => sub { '' },
5094             );
5095              
5096              
5097             =head4 test_step_id
5098              
5099              
5100             =cut
5101              
5102             has test_step_id =>
5103             (is => 'ro',
5104             required => 1,
5105             default => sub { '' },
5106             );
5107              
5108              
5109             =head4 timestamp
5110              
5111              
5112             =cut
5113              
5114             has timestamp =>
5115             (is => 'ro',
5116             required => 1,
5117             default => sub { Cucumber::Messages::Timestamp->new() },
5118             );
5119              
5120              
5121             }
5122              
5123             package Cucumber::Messages::Timestamp {
5124             $Cucumber::Messages::Timestamp::VERSION = '34.0.1';
5125             =head2 Cucumber::Messages::Timestamp
5126              
5127             =head3 DESCRIPTION
5128              
5129             Represents the Timestamp message in Cucumber's
5130             L.
5131              
5132              
5133              
5134             =head3 ATTRIBUTES
5135              
5136             =cut
5137              
5138 3     3   18 use Moo;
  3         4  
  3         9  
5139             extends 'Cucumber::Messages::Message';
5140              
5141 3     3   838 use Scalar::Util qw( blessed );
  3         4  
  3         531  
5142              
5143             my %types = (
5144             seconds => 'number',
5145             nanos => 'number',
5146             );
5147              
5148             # This is a work-around for the fact that Moo doesn't have introspection
5149             # and Perl doesn't have boolean values...
5150             sub _types {
5151 0     0     return \%types;
5152             }
5153              
5154              
5155              
5156             =head4 seconds
5157              
5158             Represents seconds of UTC time since Unix epoch
5159             1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to
5160             9999-12-31T23:59:59Z inclusive.
5161             =cut
5162              
5163             has seconds =>
5164             (is => 'ro',
5165             required => 1,
5166             default => sub { 0 },
5167             );
5168              
5169              
5170             =head4 nanos
5171              
5172             Non-negative fractions of a second at nanosecond resolution. Negative
5173             second values with fractions must still have non-negative nanos values
5174             that count forward in time. Must be from 0 to 999,999,999
5175             inclusive.
5176             =cut
5177              
5178             has nanos =>
5179             (is => 'ro',
5180             required => 1,
5181             default => sub { 0 },
5182             );
5183              
5184              
5185             }
5186              
5187             package Cucumber::Messages::UndefinedParameterType {
5188             $Cucumber::Messages::UndefinedParameterType::VERSION = '34.0.1';
5189             =head2 Cucumber::Messages::UndefinedParameterType
5190              
5191             =head3 DESCRIPTION
5192              
5193             Represents the UndefinedParameterType message in Cucumber's
5194             L.
5195              
5196              
5197              
5198             =head3 ATTRIBUTES
5199              
5200             =cut
5201              
5202 3     3   16 use Moo;
  3         4  
  3         9  
5203             extends 'Cucumber::Messages::Message';
5204              
5205 3     3   832 use Scalar::Util qw( blessed );
  3         3  
  3         1399  
5206              
5207             my %types = (
5208             expression => 'string',
5209             name => 'string',
5210             );
5211              
5212             # This is a work-around for the fact that Moo doesn't have introspection
5213             # and Perl doesn't have boolean values...
5214             sub _types {
5215 0     0     return \%types;
5216             }
5217              
5218              
5219              
5220             =head4 expression
5221              
5222              
5223             =cut
5224              
5225             has expression =>
5226             (is => 'ro',
5227             required => 1,
5228             default => sub { '' },
5229             );
5230              
5231              
5232             =head4 name
5233              
5234              
5235             =cut
5236              
5237             has name =>
5238             (is => 'ro',
5239             required => 1,
5240             default => sub { '' },
5241             );
5242              
5243              
5244             }
5245              
5246             1;
5247              
5248             __END__