Test2::Warnings(3)
π NAME π
okay so bestie, welcome to the Test2::Warnings(3) manual page, a.k.a. User Contributed Perl Documentation. This module is Test2::Warnings, and its whole thing is testing for warnings and also testing for the lack of them. Both. Iconic.
β¨ VERSION β¨
version 0.038 β write it down, bestie. π
π¦ SYNOPSIS π¦
First vibe check:
use Test2::V0;
use Test::Warnings;
pass('yay!');
done_testing;
and it emits TAP like:
ok 1 - yay!
ok 2 - no (unexpected) warnings (via done_testing)
1..2
Also:
use Test::More tests => 3;
use Test::Warnings 0.005 ':all';
pass('yay!');
like(warning { warn "oh noes!" }, qr/^oh noes/, 'we warned');
and this one emits TAP:
ok 1 - yay!
ok 2 - we warned
ok 3 - no (unexpected) warnings (via END block)
1..3
πΈ DESCRIPTION πΈ
For the full documentation, go see Test::Warnings β it's the main character for docs. π
For now, this is a simple wrapper around Test::Warnings, but there's a plan to make this a full port, eject all the old Test::Builder compatibility, and use the Test2 suite correctly. So yeah, glow-up roadmap, no cap.
π«Ά SUPPORT π«Ά
Bugs may be submitted through the RT bug tracker: https://rt.cpan.org/Public/Dist/Display.html?Name=Test-Warnings (or email bug-Test-Warnings@rt.cpan.org, which is mailto:bug-Test-Warnings@rt.cpan.org).
There is also a mailing list available for users of this distribution, at http://lists.perl.org/list/perl-qa.html.
There is also an IRC channel available for users of this distribution, at #perl on irc.perl.org β link vibe: irc://irc.perl.org/#perl-qa.
I'm also usually active on IRC, as 'ether' at irc.perl.org and irc.libera.chat.
π AUTHOR π
Karen Etheridge β ether@cpan.org. Author slay. π
π COPYRIGHT AND LICENCE π
This software is copyright (c) 2013 by Karen Etheridge.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. Periodt.
That's the whole page, bestie! π«Ά Source/version: perl v5.42.0, date: 2025-02-02 β Test2::Warnings(3) out. π
π¦ where this page comes from
- alpine 3.23: perl-test-warnings-doc 0.038-r0 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- opensuse-leap 16.0: perl-Test-Warnings 0.38.0-160000.2.2 Β· Artistic-1.0 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