perl-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stas Bekman <s...@stason.org>
Subject Re: svn commit: r111461 - /perl/modperl/trunk/t/conf/modperl_extra.pl /perl/modperl/trunk/t/conf/post_config_startup.pl
Date Fri, 10 Dec 2004 03:11:44 GMT
stas@apache.org wrote:
> Author: stas
> Date: Thu Dec  9 19:09:28 2004
> New Revision: 111461
> 
> URL: http://svn.apache.org/viewcvs?view=rev&rev=111461
> Log:
> move the code that doesn't have to be run at startup phase to the 
> post_config phase (have those in a separate file post_config_startup.pl 
> which is require()'d by a registered post_config callback

What I don't understand is why the following patch, which moves seemingly 
unrelated to config code to post_config phase, breaks a bunch of tests. Ideas?

Index: t/conf/modperl_extra.pl
===================================================================
--- t/conf/modperl_extra.pl	(revision 111461)
+++ t/conf/modperl_extra.pl	(working copy)
@@ -35,8 +35,6 @@

  test_modperl_env();

-test_method_obj();
-
  ### only subs below this line ###

  sub reorg_INC {
@@ -144,19 +142,5 @@
      $ENV{MODPERL_EXTRA_PL} = __FILE__;
  }

-sub test_method_obj {
-    # see t/modperl/methodobj
-    require TestModperl::methodobj;
-    $TestModperl::MethodObj = TestModperl::methodobj->new;
-}

-sub ModPerl::Test::add_config {
-    my $r = shift;
-
-    #test adding config at request time
-    $r->add_config(['require valid-user']);
-
-    Apache::OK;
-}
-
  1;
Index: t/conf/post_config_startup.pl
===================================================================
--- t/conf/post_config_startup.pl	(revision 111461)
+++ t/conf/post_config_startup.pl	(working copy)
@@ -39,6 +39,8 @@

  test_server_shutdown_cleanup_register();

+test_method_obj();
+
  ### only subs below this line ###


@@ -111,4 +113,19 @@
  }


+sub test_method_obj {
+    # see t/modperl/methodobj
+    require TestModperl::methodobj;
+    $TestModperl::MethodObj = TestModperl::methodobj->new;
+}
+
+sub ModPerl::Test::add_config {
+    my $r = shift;
+
+    #test adding config at request time
+    $r->add_config(['require valid-user']);
+
+    Apache::OK;
+}
+
  1;



-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Mime
View raw message