r76249 - in /trunk/libcgi-application-plugin-validaterm-perl: Changes META.yml Makefile.PL README debian/changelog debian/patches/ lib/CGI/Application/Plugin/ValidateRM.pm t/01_basic.t t/99_pod.t

periapt-guest at users.alioth.debian.org periapt-guest at users.alioth.debian.org
Tue Jun 21 19:56:41 UTC 2011


Author: periapt-guest
Date: Tue Jun 21 19:56:32 2011
New Revision: 76249

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=76249
Log:
new upstream release

Removed:
    trunk/libcgi-application-plugin-validaterm-perl/debian/patches/
Modified:
    trunk/libcgi-application-plugin-validaterm-perl/Changes
    trunk/libcgi-application-plugin-validaterm-perl/META.yml
    trunk/libcgi-application-plugin-validaterm-perl/Makefile.PL
    trunk/libcgi-application-plugin-validaterm-perl/README
    trunk/libcgi-application-plugin-validaterm-perl/debian/changelog
    trunk/libcgi-application-plugin-validaterm-perl/lib/CGI/Application/Plugin/ValidateRM.pm
    trunk/libcgi-application-plugin-validaterm-perl/t/01_basic.t
    trunk/libcgi-application-plugin-validaterm-perl/t/99_pod.t

Modified: trunk/libcgi-application-plugin-validaterm-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcgi-application-plugin-validaterm-perl/Changes?rev=76249&op=diff
==============================================================================
--- trunk/libcgi-application-plugin-validaterm-perl/Changes (original)
+++ trunk/libcgi-application-plugin-validaterm-perl/Changes Tue Jun 21 19:56:32 2011
@@ -1,4 +1,11 @@
 Revision history for Perl extension CGI::Application::Plugin::ValidateRM.
+
+2.4 July 20th, 2011
+    No functional changes.
+
+    Fixed Perl 5.12 compatibility, thanks to Nicholas Bamber.  (RT#67894)
+
+    Also, some other code-cleanup.
 
 2.3 Wed Oct 22 23:05:29 EDT 2008
     - Fix broken test in t/forward.t  (#35056)

Modified: trunk/libcgi-application-plugin-validaterm-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcgi-application-plugin-validaterm-perl/META.yml?rev=76249&op=diff
==============================================================================
--- trunk/libcgi-application-plugin-validaterm-perl/META.yml (original)
+++ trunk/libcgi-application-plugin-validaterm-perl/META.yml Tue Jun 21 19:56:32 2011
@@ -1,6 +1,6 @@
 ---
 name: CGI-Application-Plugin-ValidateRM
-version: 2.3
+version: 2.4
 author:
   - 'Mark Stosberg <mark at summersault.com>'
 abstract: Help validate CGI::Application run modes using Data::FormValidator
@@ -11,11 +11,13 @@
   CGI::Application: 3
   Data::FormValidator: 3.7
   HTML::FillInForm: 1.07
+configure_requires:
+  Module::Build: 0.340201
 provides:
   CGI::Application::Plugin::ValidateRM:
     file: lib/CGI/Application/Plugin/ValidateRM.pm
-    version: 2.3
-generated_by: Module::Build version 0.2806
+    version: 2.4
+generated_by: Module::Build version 0.340201
 meta-spec:
-  url: http://module-build.sourceforge.net/META-spec-v1.2.html
-  version: 1.2
+  url: http://module-build.sourceforge.net/META-spec-v1.4.html
+  version: 1.4

Modified: trunk/libcgi-application-plugin-validaterm-perl/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcgi-application-plugin-validaterm-perl/Makefile.PL?rev=76249&op=diff
==============================================================================
--- trunk/libcgi-application-plugin-validaterm-perl/Makefile.PL (original)
+++ trunk/libcgi-application-plugin-validaterm-perl/Makefile.PL Tue Jun 21 19:56:32 2011
@@ -1,16 +1,16 @@
-# Note: this file was auto-generated by Module::Build::Compat version 0.03
+# Note: this file was auto-generated by Module::Build::Compat version 0.340201
 use ExtUtils::MakeMaker;
 WriteMakefile
 (
-          'PL_FILES' => {},
-          'INSTALLDIRS' => 'site',
           'NAME' => 'CGI::Application::Plugin::ValidateRM',
-          'EXE_FILES' => [],
           'VERSION_FROM' => 'lib/CGI/Application/Plugin/ValidateRM.pm',
           'PREREQ_PM' => {
                            'CGI::Application' => '3',
-                           'HTML::FillInForm' => '1.07',
-                           'Data::FormValidator' => '3.7'
-                         }
+                           'Data::FormValidator' => '3.7',
+                           'HTML::FillInForm' => '1.07'
+                         },
+          'INSTALLDIRS' => 'site',
+          'EXE_FILES' => [],
+          'PL_FILES' => {}
         )
 ;

Modified: trunk/libcgi-application-plugin-validaterm-perl/README
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcgi-application-plugin-validaterm-perl/README?rev=76249&op=diff
==============================================================================
--- trunk/libcgi-application-plugin-validaterm-perl/README (original)
+++ trunk/libcgi-application-plugin-validaterm-perl/README Tue Jun 21 19:56:32 2011
@@ -3,9 +3,10 @@
     run modes using Data::FormValidator
 
 SYNOPSIS
-     use CGI::Application::Plugin::ValidateRM; 
+     use CGI::Application::Plugin::ValidateRM;
 
      my  $results = $self->check_rm('form_display','_form_profile') || return $self->check_rm_error_page;
+
 
      # Optionally, you can pass additional options to HTML::FillInForm->fill()
      my $results = $self->check_rm('form_display','_form_profile', { fill_password => 0 })
@@ -47,7 +48,7 @@
             my $self = shift;
             my $errs = shift;                             # <-- prepared for form reloading
             my $t = $self->load_tmpl('form_display.html');
-            $t->param($errs) if $errs;                    # <-- Also necessary. 
+            $t->param($errs) if $errs;                    # <-- Also necessary.
             # ...
 
          }
@@ -89,8 +90,8 @@
 
      sub cgiapp_init {
          my $self = shift;
- 
-         # Set some defaults for DFV unless they already exist.  
+
+         # Set some defaults for DFV unless they already exist.
          $self->param('dfv_defaults') ||
              $self->param('dfv_defaults', {
                      missing_optional_valid => 1,
@@ -149,32 +150,32 @@
      sub form_display {
             my $self = shift;
             my $errs = shift;
- 
+
             my $t = $self->load_tmpl('page.html');
- 
+
             $t->param($errs) if $errs;
             return $t->output;
      }
- 
+
      sub form_process {
             my $self = shift;
- 
+
             use CGI::Application::Plugin::ValidateRM (qw/check_rm/);
             my ($results, $err_page) = $self->check_rm('form_display','_form_profile');
-            return $err_page if $err_page; 
+            return $err_page if $err_page;
 
             #..  do something with DFV $results object now
- 
+
             my $t = $self->load_tmpl('success.html');
             return $t->output;
 
      }
- 
+
      sub _form_profile {
             return {
                     required => 'email',
                     msgs => {
-                            any_errors => 'some_errors', 
+                            any_errors => 'some_errors',
                             prefix => 'err_',
                     },
             };

Modified: trunk/libcgi-application-plugin-validaterm-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcgi-application-plugin-validaterm-perl/debian/changelog?rev=76249&op=diff
==============================================================================
--- trunk/libcgi-application-plugin-validaterm-perl/debian/changelog (original)
+++ trunk/libcgi-application-plugin-validaterm-perl/debian/changelog Tue Jun 21 19:56:32 2011
@@ -1,7 +1,7 @@
-libcgi-application-plugin-validaterm-perl (2.3-1) UNRELEASED; urgency=low
+libcgi-application-plugin-validaterm-perl (2.4-1) UNRELEASED; urgency=low
 
   WAITS-FOR: Its brothers and sisters
 
   * Split out from libcgi-application-basic-plugin-bundle-perl (Closes: #630952)
 
- -- Nicholas Bamber <nicholas at periapt.co.uk>  Sat, 18 Jun 2011 12:26:48 +0100
+ -- Nicholas Bamber <nicholas at periapt.co.uk>  Tue, 21 Jun 2011 20:59:49 +0100

Modified: trunk/libcgi-application-plugin-validaterm-perl/lib/CGI/Application/Plugin/ValidateRM.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcgi-application-plugin-validaterm-perl/lib/CGI/Application/Plugin/ValidateRM.pm?rev=76249&op=diff
==============================================================================
--- trunk/libcgi-application-plugin-validaterm-perl/lib/CGI/Application/Plugin/ValidateRM.pm (original)
+++ trunk/libcgi-application-plugin-validaterm-perl/lib/CGI/Application/Plugin/ValidateRM.pm Tue Jun 21 19:56:32 2011
@@ -1,35 +1,26 @@
 package CGI::Application::Plugin::ValidateRM;
+use base ('Exporter','AutoLoader');
 use HTML::FillInForm;
 use Data::FormValidator;
 use strict;
-use vars qw($VERSION @ISA @EXPORT @EXPORT_OK);
-
-require Exporter;
-
- at ISA = qw(Exporter AutoLoader);
-# Items to export into callers namespace by default. Note: do not export
-# names by default without a very good reason. Use EXPORT_OK instead.
-# Do not simply export all your public functions/methods/constants.
- at EXPORT = qw(
+
+our @EXPORT = qw(
     &dfv_results
     &dfv_error_page
     &check_rm_error_page
 	&check_rm
-	&validate_rm	
+	&validate_rm
 );
 
- at EXPORT_OK = qw(
-);
-
-$VERSION = '2.3';
+our $VERSION = '2.4';
 
 sub check_rm {
      my $self = shift;
 	 my $return_rm = shift || die 'missing required return run mode';
      my $profile_in = shift || die 'missing required profile';
-     my $fif_params = shift || {}; 
-
-	# If the profile is not a hash reference, 
+     my $fif_params = shift || {};
+
+	# If the profile is not a hash reference,
 	# assume it's a CGI::App method
 	my $profile;
 	if (ref $profile_in eq 'HASH') {
@@ -45,19 +36,19 @@
         }
 
 	}
- 
+
      require Data::FormValidator;
      my $dfv = Data::FormValidator->new({}, $self->param('dfv_defaults') );
 	 my $r =$dfv->check($self->query,$profile);
      $self->{'__DFV_RESULT'} = $r;
 
-     # Pass the params through the object so the user 
+     # Pass the params through the object so the user
      # can just call dfv_error_page() later
      $self->{'__DFV_RETURN_RM'}  = $return_rm;
      $self->{'__DFV_FIF_PARAMS'} = $fif_params;
 
      if (wantarray) {
-         # We have to call the function non-traditionally to achieve mix-in happiness. 
+         # We have to call the function non-traditionally to achieve mix-in happiness.
          return $r, dfv_error_page($self);
      }
      else {
@@ -118,7 +109,7 @@
 
 =head1 SYNOPSIS
 
- use CGI::Application::Plugin::ValidateRM; 
+ use CGI::Application::Plugin::ValidateRM;
 
  my  $results = $self->check_rm('form_display','_form_profile') || return $self->check_rm_error_page;
 
@@ -130,18 +121,18 @@
 =head1 DESCRIPTION
 
 CGI::Application::Plugin::ValidateRM helps to validate web forms when using the
-CGI::Application framework and the Data::FormValidator module. 
+CGI::Application framework and the Data::FormValidator module.
 
 =head2 check_rm()
 
 Validates a form displayed in a run mode with a C<Data::FormValidator> profile, returning
-the results and possibly an a version of the form page with errors marked on the page. 
+the results and possibly an a version of the form page with errors marked on the page.
 
 In scalar context, it returns simply the Data::FormValidator::Results object
 which conveniently evaluates to false in a boolean context if there were any missing
 or invalide fields. This is the recommended calling convention.
 
-In list context, it returns the results object followed by the error page, if any. 
+In list context, it returns the results object followed by the error page, if any.
 This was the previous recommended syntax, and was used like this:
 
  my ($results,$err_page) = $self->check_rm('form_display','_form_profile');
@@ -158,25 +149,25 @@
 returned as a second output parameter.
 
 The errors will be passed in as a hash reference, which can then be handed to a
-templating system for display. Following the above example, the form_display() routine might look like: 
+templating system for display. Following the above example, the form_display() routine might look like:
 
  sub form_display {
     my $self = shift;
     my $errs = shift;                             # <-- prepared for form reloading
     my $t = $self->load_tmpl('form_display.html');
-    $t->param($errs) if $errs;                    # <-- Also necessary. 
+    $t->param($errs) if $errs;                    # <-- Also necessary.
     # ...
 
  }
 
 The fields should be prepared using Data::FormValidator's
-built-in support for returning error messages as a hash reference.   
+built-in support for returning error messages as a hash reference.
 See the documentation for C<msgs> in the L<Data::FormValidator::Results>
 documentation.
 
 Returning the errors with a prefix, such as "err_" is recommended. Using
 C<any_errors> is also recommended to make it easy to display a general "we have
-some errors" message.  
+some errors" message.
 
 HTML::Template users may want to pass C<die_on_bad_params=E<gt>0> to the
 HTML::Template constructor to prevent the presence of the "err_" tokens from
@@ -190,7 +181,7 @@
 =item HTML::FillInForm options (optional)
 
 If desired, you can pass additional options to the HTML::FillInForm C<fill>
-method through a hash reference. See an example above. 
+method through a hash reference. See an example above.
 
 =back
 
@@ -208,8 +199,8 @@
 
  sub cgiapp_init {
      my $self = shift;
- 
-     # Set some defaults for DFV unless they already exist.  
+
+     # Set some defaults for DFV unless they already exist.
      $self->param('dfv_defaults') ||
          $self->param('dfv_defaults', {
                  missing_optional_valid => 1,
@@ -226,13 +217,13 @@
 
 Now all my applications that inherit from a super class with this
 C<cgiapp_init()> routine and have these defaults, so I don't have
-to add them to every profile. 
+to add them to every profile.
 
 =head2 CGI::Application::Plugin::Forward support
 
 Experimental support has been added for CGI::Application::Plugin::Forward,
-which keeps the current run mode up to date. This would be useful if you 
-were automatically generating a template name based on the run mode name, 
+which keeps the current run mode up to date. This would be useful if you
+were automatically generating a template name based on the run mode name,
 and you wanted this to work with the form run mode used with ::ValidateRM.
 
 If we detect that ::Forward is loaded, we will set the current run mode name to
@@ -240,13 +231,13 @@
 the previous value afterwards. There is a caveat: This currently only works
 when the run name name is the same as the subroutine name for the form page.
 If they differ, the current run mode name inside of the form page will be
-inaccurate. If this is a problem for you, get in touch to discuss a solution. 
+inaccurate. If this is a problem for you, get in touch to discuss a solution.
 
 =head2 check_rm_error_page()
 
 After check_rm() is called this accessor method can be used to retrieve the
 error page described in the check_rm() docs above. The method has an alias
-named C<dfv_error_page()> if you find that more intuitive. 
+named C<dfv_error_page()> if you find that more intuitive.
 
 =head2 dfv_results()
 
@@ -254,9 +245,9 @@
 
 After C<check_rm()> or C<validate_rm()> has been called, the DFV results object
 can also be accessed through this method. I expect this to be most useful to
-other plugin authors. 
-
-=head2 validate_rm() 
+other plugin authors.
+
+=head2 validate_rm()
 
 Works like C<check_rm> above, but returns the old style C<$valid> hash
 reference instead of the results object. It's no longer recommended, but still
@@ -271,32 +262,32 @@
  sub form_display {
  	my $self = shift;
  	my $errs = shift;
- 
+
  	my $t = $self->load_tmpl('page.html');
- 
+
  	$t->param($errs) if $errs;
  	return $t->output;
  }
- 
+
  sub form_process {
  	my $self = shift;
- 
+
  	use CGI::Application::Plugin::ValidateRM (qw/check_rm/);
  	my ($results, $err_page) = $self->check_rm('form_display','_form_profile');
- 	return $err_page if $err_page; 
+ 	return $err_page if $err_page;
 
 	#..  do something with DFV $results object now
- 
+
  	my $t = $self->load_tmpl('success.html');
  	return $t->output;
 
  }
- 
+
  sub _form_profile {
  	return {
  		required => 'email',
 		msgs => {
-			any_errors => 'some_errors', 
+			any_errors => 'some_errors',
 			prefix => 'err_',
 		},
  	};
@@ -323,7 +314,7 @@
 =head1 MAILING LIST
 
 If you have any questions, comments, bug reports or feature suggestions,
-post them to the support mailing list! This the Data::FormValidator list. 
+post them to the support mailing list! This the Data::FormValidator list.
 To join the mailing list, visit L<http://lists.sourceforge.net/lists/listinfo/cascade-dataform>
 
 =head1 LICENSE
@@ -338,7 +329,7 @@
 
 or
 
-b) the "Artistic License" 
+b) the "Artistic License"
 
 This program is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of

Modified: trunk/libcgi-application-plugin-validaterm-perl/t/01_basic.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcgi-application-plugin-validaterm-perl/t/01_basic.t?rev=76249&op=diff
==============================================================================
--- trunk/libcgi-application-plugin-validaterm-perl/t/01_basic.t (original)
+++ trunk/libcgi-application-plugin-validaterm-perl/t/01_basic.t Tue Jun 21 19:56:32 2011
@@ -34,7 +34,6 @@
 
 
 {
-    use UNIVERSAL (qw/can/);
     ok( $t3_obj->can('dfv_results'), "has dfv_results method" );
     ok( $t3_obj->can('dfv_error_page'), "has dfv_error_page method" );
     ok( $t3_obj->can('check_rm_error_page'), "has check_rm_error_page method" );

Modified: trunk/libcgi-application-plugin-validaterm-perl/t/99_pod.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcgi-application-plugin-validaterm-perl/t/99_pod.t?rev=76249&op=diff
==============================================================================
--- trunk/libcgi-application-plugin-validaterm-perl/t/99_pod.t (original)
+++ trunk/libcgi-application-plugin-validaterm-perl/t/99_pod.t Tue Jun 21 19:56:32 2011
@@ -1,28 +1,4 @@
 use Test::More;
- 
-use File::Spec;
-use File::Find;
-use strict;
- 
-eval {
-  require Test::Pod;
-  Test::Pod->import;
-};
- 
-my @files;
- 
-if ($@) {
-  plan skip_all => "Test::Pod required for testing POD";
-}
-else {
-  my $blib = File::Spec->catfile(qw(blib lib));
-  find(\&wanted, $blib);
-  plan tests => scalar @files;
-  foreach my $file (@files) {
-    pod_file_ok($file);
-  }
-}
- 
-sub wanted {
-  push @files, $File::Find::name if /\.p(l|m|od)$/;
-} 
+eval "use Test::Pod 1.00";
+plan skip_all => "Test::Pod 1.00 required for testing POD" if $@;
+all_pod_files_ok();




More information about the Pkg-perl-cvs-commits mailing list