Skip Menu |

This queue is for tickets about the CGI-Application-Plugin-DebugScreen CPAN distribution.

Report information
The Basics
Id: 16727
Status: resolved
Priority: 0/
Queue: CGI-Application-Plugin-DebugScreen

People
Owner: Nobody in particular
Requestors: mark [...] summersault.com
Cc:
AdminCc:

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



Subject: Makefile.PL should require 4.0
Some people on the CGI::App list are reporting test failures that are a result of not requiring CGI::Application => 4 in the Makefile.PL One of the tests uses "add_callback()" which didn't appear until 4.0.
Subject: test script should be a CGI::Application subclass
From: ceeshek [...] gmail.com
[guest - Sat Dec 24 08:09:15 2005]: Show quoted text
> Some people on the CGI::App list are reporting test failures that are > a result of not requiring CGI::Application => 4 in the Makefile.PL > > One of the tests uses "add_callback()" which didn't appear until 4.0.
Also, since add_callback is called inside 'import', you can only ever load the plugin while inside a CGI::Application subclass (which makes sense). However, since the test script doesn't create a CGI::Application subclass when it loads the plugin, it will always fail with the following error: t/00_compile....NOK 1 # Failed test 'use CGI::Application::Plugin::DebugScreen;' # in t/00_compile.t at line 4. # Tried to use 'CGI::Application::Plugin::DebugScreen'. # Error: Can't locate object method "add_callback" via package "main" at /root/.cpan/build/CGI-Application-Plugin-DebugScreen-0.05/blib/lib/CGI/Application/Plugin/DebugScreen.pm line 145. The attached patch fixed the test script Cheers, Cees
--- 00_compile.t.orig 2005-12-24 08:23:18.000000000 -0500 +++ 00_compile.t 2005-12-24 08:23:24.000000000 -0500 @@ -1,4 +1,6 @@ -use strict; +package DebugScreen::Test; + use Test::More tests => 1; -BEGIN { use_ok('CGI::Application::Plugin::DebugScreen') }; +use base qw(CGI::Application); +use_ok('CGI::Application::Plugin::DebugScreen');
[guest - Sat Dec 24 08:30:00 2005]: Show quoted text
> [guest - Sat Dec 24 08:09:15 2005]: >
> > Some people on the CGI::App list are reporting test failures that
> are
> > a result of not requiring CGI::Application => 4 in the Makefile.PL > > > > One of the tests uses "add_callback()" which didn't appear until
> 4.0. > > > Also, since add_callback is called inside 'import', you can only ever > load the plugin while inside a CGI::Application subclass (which makes > sense). However, since the test script doesn't create a > CGI::Application subclass when it loads the plugin, it will always > fail > with the following error: > > t/00_compile....NOK 1 > # Failed test 'use CGI::Application::Plugin::DebugScreen;' > # in t/00_compile.t at line 4. > # Tried to use 'CGI::Application::Plugin::DebugScreen'. > # Error: Can't locate object method "add_callback" via package > "main" at > /root/.cpan/build/CGI-Application-Plugin-DebugScreen- > 0.05/blib/lib/CGI/Application/Plugin/DebugScreen.pm > line 145. > > > The attached patch fixed the test script > > Cheers, > > Cees
OK. I see. Please wait... atsushi
[guest - Sat Dec 24 22:33:02 2005]: Show quoted text
> [guest - Sat Dec 24 08:30:00 2005]: >
> > [guest - Sat Dec 24 08:09:15 2005]: > >
> > > Some people on the CGI::App list are reporting test failures that
> > are
> > > a result of not requiring CGI::Application => 4 in the
> Makefile.PL
> > > > > > One of the tests uses "add_callback()" which didn't appear until
> > 4.0. > > > > > > Also, since add_callback is called inside 'import', you can only
> ever
> > load the plugin while inside a CGI::Application subclass (which
> makes
> > sense). However, since the test script doesn't create a > > CGI::Application subclass when it loads the plugin, it will always > > fail > > with the following error: > > > > t/00_compile....NOK 1 > > # Failed test 'use CGI::Application::Plugin::DebugScreen;' > > # in t/00_compile.t at line 4. > > # Tried to use 'CGI::Application::Plugin::DebugScreen'. > > # Error: Can't locate object method "add_callback" via package > > "main" at > > /root/.cpan/build/CGI-Application-Plugin-DebugScreen- > > 0.05/blib/lib/CGI/Application/Plugin/DebugScreen.pm > > line 145. > > > > > > The attached patch fixed the test script > > > > Cheers, > > > > Cees
> > OK. > I see. > Please wait... > > atsushi >
Hi. I updated new version. Please test it. atsushi
closed