Test::...:Simple(3pm)
πΈ NAME πΈ
Test::Inline::Content::Simple β it's giving Simple templating Content Handler π
okay bestie so this is the page for Test::...:Simple(3pm) (yes the header is being extra, the real one is Test::Inline::Content::Simple) and she is so much simpler than she looks, trust π«Ά
β¨ VERSION β¨
version 2.214 β that's the one, no cap π
π SYNOPSIS π
so here's the vibe, in your inline2test.tpl:
In your inline2test.tpl
----------------------
#!/usr/bin/perl -w
use strict;
use Test::More [% plan %];
$| = 1;
[% tests %]
1;
like... it's a template, it's cute, it does the thing π
π¦ DESCRIPTION π¦
okay so real talk: it is relatively common to want to customise the contents of the generated test files β you know, to set up custom environment things on an all-scripts basis, instead of doing it file by file (which is what =begin SETUP blocks are for). π
and Test::Inline::Content::Simple lets you do exactly that, using a very simple Template Toolkit style template to define all that info. iconic behaviour honestly.
she contains only two tags, and they are plan and tests. that's it. two. minimal queen π
- the
plantag gets inserted as either"tests =" 123>or'no_plan' - the
teststag gets replaced by the actual testing code
periodt π
π METHODS π
π new $filename
manually create a new Test::Inline::Content::Simple object. she takes as a parameter a single filename which should contain the template code. π
returns a new Test::Inline::Content::Simple object, or undef on error. (so like, check it, bestie π)
πΈ template
the template accessor returns the template content for the object. she just hands it over. simple as that π«Ά
π§ process $Inline, $Script
the process method is unchanged from Test::Inline::Content. nothing new here, same energy, same method β¨
π₯ SUPPORT π₯
see the main SUPPORT section π
bugs may be submitted through the RT bug tracker <https://rt.cpan.org/Public/Dist/Display.html?Name=Test-Inline> (or bug-Test-Inline@rt.cpan.org <mailto:bug-Test-Inline@rt.cpan.org>). ngl if you found a bug, tell them, they wanna know π
π AUTHOR π
Adam Kennedy <adamk@cpan.org> β the main character who wrote this, we stan π«Ά
π COPYRIGHT AND LICENSE π
this software is copyright (c) 2003 by Adam Kennedy.
this is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. slay, open source π
and that's the whole page bestie!! this doc came to you courtesy of perl v5.32.0 dated 2021-01-31, filed under Test::...:Simple(3pm) (the header said it, not me π) β mwah, go write some tests πβ¨
π¦ where this page comes from
- debian bookworm: libtest-inline-perl 2.214-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- debian trixie: libtest-inline-perl 2.214-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu jammy: libtest-inline-perl 2.214-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libtest-inline-perl 2.214-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libtest-inline-perl 2.214-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libtest-inline-perl 2.214-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms