Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Perl-Critic CPAN distribution.

Report information
The Basics
Id: 24924
Status: resolved
Priority: 0/
Queue: Perl-Critic

People
Owner: Nobody in particular
Requestors: Bernhard.Schmalhofer [...] biomax.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: False positive in TestingAndDebugging::RequireTestLabels
Date: Tue, 13 Feb 2007 14:56:25 +0100
To: bug-Perl-Critic [...] rt.cpan.org
From: Bernhard Schmalhofer <Bernhard.Schmalhofer [...] biomax.com>
Hi, when running Perl::Critic 1.02 over my test scripts, I probably ran accross a false positive in TestingAndDebugging::RequireTestLabels. I boiled it down to a short test: Show quoted text
devel> perlcritic --severity=3 t.pl
. . Test without a label at line 13, column 1. Add a label argument to all Test::More functions. (Severity: 3) . . . Best regards, Berhard -- ************************************************** Dipl.-Physiker Bernhard Schmalhofer Senior Developer Biomax Informatics AG Lochhamer Str. 11 82152 Martinsried, Germany Tel: +49 89 895574-839 Fax: +49 89 895574-825 eMail: Bernhard.Schmalhofer@biomax.com Website: www.biomax.com **************************************************
use strict; use warnings; use Test::More; plan( tests => 1 ); sub get_key_val_pairs { return 'key1' => 'val2', 'key2' => 'val2'; } is_deeply( { get_key_val_pairs() }, { 'key1' => 'val2', 'key2' => 'val2' }, 'Boldly criticize where nobody has criticize before.' );
I haven't been able to reproduce, and I don't have access to access to a darwin platform. According to CPAN-Testers, other darwin users have not had this problem. So I'm going to reject this bug for now.
On Wed May 23 00:44:05 2007, THALJEF wrote: Show quoted text
> I haven't been able to reproduce, and I don't have access to access to a > darwin platform. According to CPAN-Testers, other darwin users have not > had this problem. So I'm going to reject this bug for now.
I've reproduced the problem. It's a PPI bug parsing the first hash constructor. I've added a failing TODO test to the P::C svn. Running the test with SVN PPI makes the test pass. Unfortunately, PPI development seems to have stalled...
Subject: Re: [rt.cpan.org #24924] False positive in TestingAndDebugging::RequireTestLabels
Date: Wed, 23 May 2007 19:33:24 -0700 (PDT)
To: bug-Perl-Critic [...] rt.cpan.org
From: Jeffrey Thalhammer <jeffrey_thalhammer [...] yahoo.com>
Show quoted text
> I've reproduced the problem. It's a PPI bug parsing > the first hash > constructor. I've added a failing TODO test to the > P::C svn. Running > the test with SVN PPI makes the test pass. > Unfortunately, PPI > development seems to have stalled...
Woops. My response was intended for a different ticket. Yes, this is definitely a real bug. Sorry for the confusion. -Jeff Show quoted text
____________________________________________________________________________________ Bored stiff? Loosen up... Download and play hundreds of games for free on Yahoo! Games. http://games.yahoo.com/games/front
From: x.perl-critic-requiretestlabels-false-positive-bug-report [...] chatterjee.net
On Wed May 23 00:44:05 2007, THALJEF wrote: Show quoted text
> I haven't been able to reproduce, and I don't have access to access to a > darwin platform. According to CPAN-Testers, other darwin users have not > had this problem. So I'm going to reject this bug for now.
I can reproduce this problem as well, on a Linux platform. When running the following code: #!/usr/bin/perl use Test::More tests => 1; use strict; use warnings; is_deeply( [], [], 'sample test label' ); I get the following false positive error message back: "Test without a label at line 7, column 1. Add a label argument to all Test::More functions. (Severity: 3)" This is with Perl::Critic 1.078 running with PPI 1.118, on Perl 5.6.1 on a Linux i686 platform.
From: ELLIOTJS [...] cpan.org
This bug is fixed with the release of PPI 1.200.
From: Bernhard.Schmalhofer [...] gmx.de
On Mo. 15. Okt. 2007, 01:07:34, ELLIOTJS wrote: Show quoted text
> This bug is fixed with the release of PPI 1.200.
Yes, I installed PPI 1.200 and removed the ## no critic (TestingAndDebugging::RequireTestLabels) comments. Almost all false positives have gone away. For the remaining false positive I extracted a small test case: package main; use strict; use warnings; use 5.008; use Test::More tests => 1; our $VERSION = 0.01; sub get_empty_array { return; } is_deeply( { get_empty_array() }, {}, 'get_empty_hash' ); Regards, Bernhard
From: ELLIOTJS [...] cpan.org
Problem confirmed. Fix checked in.
From: ELLIOTJS [...] cpan.org
Fix released in 1.079_003. Please test.
Subject: Re: [rt.cpan.org #24924] False positive in TestingAndDebugging::RequireTestLabels
Date: Tue, 23 Oct 2007 13:13:17 +0200
To: bug-Perl-Critic [...] rt.cpan.org
From: Bernhard Schmalhofer <Bernhard.Schmalhofer [...] biomax.com>
via RT schrieb: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=24924 > > > Fix released in 1.079_003. Please test. > > >
Yes, this looks fine indeed. I upgraded to 1.079_003 removed my '## no critic (RequireTestLabels)' and got no false positives. Thanks, Bernhard -- Dipl.-Physiker Bernhard Schmalhofer Senior Developer Biomax Informatics AG Lochhamer Str. 9, 82152 Martinsried, Germany Registergericht: Amtsgericht München, HRB 134442 Vorstand: Dr. Klaus Heumann (Vorsitzender), Dr. Hein Osenberg Vorsitzender des Aufsichtsrates: Prof. Dr. Hans-Werner Mewes Tel: +49 89 895574-839 Fax: +49 89 895574-825 eMail: Bernhard.Schmalhofer@biomax.com Website: http://www.biomax.com