Skip Menu |

This queue is for tickets about the Test-CheckChanges CPAN distribution.

Report information
The Basics
Id: 56109
Status: open
Priority: 0/
Queue: Test-CheckChanges

People
Owner: gam3-pause [...] gam3.net
Requestors: CHORNY [...] cpan.org
csjewell [...] cpan.org
Cc:
AdminCc:

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



Subject: Multiple plans in t\multi.t test.
In t\multi.t: our $name = File::Spec->catdir('t', 'bad', 'multiple', 'CHANGES'); if (-e $name) { plan skip_all => "case insensitive filesystem"; } Maybe you need an exit(0) in there, because it's not exiting... Test Summary Report ------------------- t\multi.t (Wstat: 0 Tests: 0 Failed: 0) Parse errors: More than one plan found in TAP output Files=26, Tests=37, 3 wallclock secs ( 0.28 usr + 0.11 sys = 0.39 CPU) Result: FAIL Failed 1/26 test programs. 0/37 subtests failed. C:/Users/Curtis/Desktop/Test-CheckChanges-0.14/. C:\strawberry\perl\bin\perl.exe ./Build test -- NOT OK //hint// to see the cpan-testers results for installing this module, try: reports C:/Users/Curtis/Desktop/Test-CheckChanges-0.14/. Running Build install make test had returned bad status, won't install without force C:\Users\Curtis\Desktop\Test-CheckChanges-0.14>perl -Mblib t\multi.t 1..0 # SKIP case insensitive filesystem 1..2
On Tue Mar 30 11:25:14 2010, CSJEWELL wrote: Show quoted text
> In t\multi.t: > > our $name = File::Spec->catdir('t', 'bad', 'multiple', 'CHANGES'); > if (-e $name) { > plan skip_all => "case insensitive filesystem"; > } > > Maybe you need an exit(0) in there, because it's not exiting...
And that is not Test::More problem. This tests exits correctly after "plan skip_all". use strict; use warnings; use Test::More; plan skip_all => "case insensitive filesystem"; print 'still works'; -- Alexandr Ciornii, http://chorny.net
Subject: [rt.cpan.org #56109]
Date: Wed, 25 Jul 2012 03:59:42 -0400
To: bug-test-checkchanges [...] rt.cpan.org
From: "Daniel Macks" <dmacks [...] netspace.org>
The second plan appears to be generated by the Dummy::done_testing() function. It appears that $Test::CheckChanges::test = bless {}, 'Dummy'; causes that function to be run immediately (automatically running an initializer without explicitly calling new() or other function seems needlessly surprising behavior!). Deferring doing that setup until after deciding whether to skip (see attached patch) resolves the problem for me (case-insensitive OS X) because that makes Dummy::done_testing() only generate a plan if we're *not* generating the plan to skip. dan -- Daniel Macks dmacks@netspace.org

Message body is not shown because sender requested not to inline it.

On 2012-07-25 01:00:01, dmacks@netspace.org wrote: Show quoted text
> The second plan appears to be generated by the Dummy::done_testing() > function. It appears that > > $Test::CheckChanges::test = bless {}, 'Dummy'; > > causes that function to be run immediately (automatically running an > initializer without explicitly calling new() or other function seems > needlessly surprising behavior!). Deferring doing that setup until > after deciding whether to skip (see attached patch) resolves the > problem for me (case-insensitive OS X) because that makes > Dummy::done_testing() only generate a plan if we're *not* generating > the plan to skip. > > dan > > -- > Daniel Macks > dmacks@netspace.org
This module shouldn't be generating a plan at all. It's up to the caller to call done_testing, himself, after finishing with ok_changes() or whatever.