MATSUNO★…Tokuhiro
and 1 contributors

NAME

Test::Snippet - doctest for perl

SYNOPSIS

    use Test::Snippet tests => 1;

    # simple repl:
    test_snippet(<<'...');
    $ 3+2
    5
    ...

    # tests in pod:
    test_snippet_in_pod(<<'...');
    =head1 DESCRIPTION

    ...

    =begin snippet

    $ 4*5
    20

    =end
    ...

DESCRIPTION

Test::Snippet is doctest for perl.

THIS MODULE IS IN ITS BETA QUALITY. API MAY CHANGE IN THE FUTURE.

FAQ

How does this compare to Test::Inline, or Test::Pod::Snippets?

Very similar.

But, Test::Snippet way is based on REPL(read eval print loop). This is very readable and users can run in own console!

AUTHOR

Tokuhiro Matsuno <tokuhirom@gmail.com>

THANKS TO

    Tatsuhiko Miyagawa
    charsbar

SEE ALSO

Test::Pod::Snippets, Test::Inline

LICENSE

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.