summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Williamson <public@khwilliamson.com>2013-12-26 21:43:07 -0700
committerKarl Williamson <public@khwilliamson.com>2013-12-26 22:21:54 -0700
commitfb177060d22211d76166a17b30fa8fd7880b2d76 (patch)
tree22fd839873b27ab7cb30693a034c08e5944d9d7f
parentf2cccb4cefe1541dfd66bc2d96a910470a478ebb (diff)
downloadperl-fb177060d22211d76166a17b30fa8fd7880b2d76.tar.gz
lib/diagnostics.t: Add test
This adds a test so that both =item lines of an adjacent pair get tested.
-rw-r--r--lib/diagnostics.t7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/diagnostics.t b/lib/diagnostics.t
index d6b6c82854..367424e192 100644
--- a/lib/diagnostics.t
+++ b/lib/diagnostics.t
@@ -4,7 +4,7 @@ BEGIN {
chdir '..' if -d '../pod' && -d '../t';
@INC = 'lib';
require './t/test.pl';
- plan(28);
+ plan(29);
}
BEGIN {
@@ -51,6 +51,11 @@ $warning = '';
warn 'Deep recursion on anonymous subroutine';
like $warning, qr/W recursion/,
'Message sharing its description with the following message';
+seek STDERR, 0,0;
+$warning = '';
+warn 'Deep recursion on subroutine "foo"';
+like $warning, qr/W recursion/,
+ 'Message sharing its description with the preceding message';
# Periods at end of entries in perldiag.pod get matched correctly
seek STDERR, 0,0;