Group
Extension

Matches 1

Test2-Suite ( E/EX/EXODIST/Test2-Suite-0.000163.tar.gz, EXODIST, 2024; MetaCPAN )
Test2-Suite/lib/Test2/Manual/Tooling/Formatter.pm ( view source; MetaCPAN )
to write a custom formatter, in our
case a JSONL formatter.

=head1 DESCRIPTION

This tutorial explains a minimal formatter that outputs each event as a json
string on its own line. A true formatter w
    package Test2::Formatter::MyFormatter;
    use strict;
    use warnings;

    use JSON::MaybeXS qw/encode_json/;

    use base qw/Test2::Formatter/;

    sub new { bless {}, shift }

    sub encod
ite {
        my ($self, $e, $num, $f) = @_;
        $f ||= $e->facet_data;

        print encode_json($f), "\n";
    }

    1;

=head1 LINE BY LINE

=over 4

=item use base qw/Test2::Formatter/;

All

Powered by Groonga
Maintained by Kenichi Ishigaki <ishigaki@cpan.org>. If you find anything, submit it on GitHub.