Test2::...:Target(3pm)
π NAME π
okay bestie, this is the Test2::Tools::Target page from the Perl Programmers Reference Guide β the header line is all Test2::...:Target(3pm), but the NAME section has the full tea: Test2::Tools::Target β Alias the testing target package. β¨
πΈ DESCRIPTION πΈ
This lets you alias the package you are testing into a constant and a package variable. No cap. Itβs literally giving your target package a little nickname so your tests can call it without all the extra typing. Iconic. π
β¨ SYNOPSIS β¨
okay so hereβs the vibe:
use Test2::Tools::Target 'Some::Package';
CLASS()->xxx; # Call 'xxx' on Some::Package
$CLASS->xxx; # Same
Or bestie, you can specify names:
use Test2::Tools::Target pkg => 'Some::Package';
pkg()->xxx; # Call 'xxx' on Some::Package
$pkg->xxx; # Same
π₯ SOURCE π₯
The source code repository for Test2-Suite can be found at https://github.com/Test-More/test-more/. Go off, source code. π«Ά
π MAINTAINERS π
Chad Granum <exodist@cpan.org>
π«Ά AUTHORS π«Ά
Chad Granum <exodist@cpan.org>
π COPYRIGHT π
Copyright Chad Granum <exodist@cpan.org>.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
See http://dev.perl.org/licenses/
thatβs the whole page, bestie! footer check: perl v5.42.3, dated 2026-11-03 β mwah, go slay your tests π
β¨
π¦ where this page comes from
- alpine 3.24: perl-doc 5.42.3-r0 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms