cvs commit: modperl-2.0/t/response/TestAPI conn_rec.pm

2002-08-15 Thread stas

stas2002/08/15 01:42:55

  Modified:xs/Apache/Connection Apache__Connection.h
   xs/maps  modperl_functions.map apache_functions.map
   xs/tables/current/ModPerl FunctionTable.pm
   t/response/TestAPI conn_rec.pm
  Log:
  add a wrapper for ap_get_remote_host + tests
  
  Revision  ChangesPath
  1.4   +8 -0  modperl-2.0/xs/Apache/Connection/Apache__Connection.h
  
  Index: Apache__Connection.h
  ===
  RCS file: /home/cvs/modperl-2.0/xs/Apache/Connection/Apache__Connection.h,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- Apache__Connection.h  30 Jan 2002 03:30:24 -  1.3
  +++ Apache__Connection.h  15 Aug 2002 08:42:55 -  1.4
   -11,3 +11,11 
   
   return socket;
   }
  +
  +static MP_INLINE
  +char *mpxs_Apache__Connection_get_remote_host(pTHX_ conn_rec *c,
  +  int type,
  +  apr_table_t *dir_config)
  +{
  +return ap_get_remote_host(c, (void *)dir_config, type, NULL);
  +}
  
  
  
  1.40  +2 -0  modperl-2.0/xs/maps/modperl_functions.map
  
  Index: modperl_functions.map
  ===
  RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v
  retrieving revision 1.39
  retrieving revision 1.40
  diff -u -r1.39 -r1.40
  --- modperl_functions.map 21 May 2002 02:50:16 -  1.39
  +++ modperl_functions.map 15 Aug 2002 08:42:55 -  1.40
   -64,6 +64,8 
   
   MODULE=Apache::Connection
mpxs_Apache__Connection_client_socket | | c, s=NULL
  + mpxs_Apache__Connection_get_remote_host | | c, type=REMOTE_NAME, dir_config=Nullsv
  +
   
   MODULE=Apache::Filter
modperl_filter_attributes | MPXS_ | ... | MODIFY_CODE_ATTRIBUTES
  
  
  
  1.56  +0 -1  modperl-2.0/xs/maps/apache_functions.map
  
  Index: apache_functions.map
  ===
  RCS file: /home/cvs/modperl-2.0/xs/maps/apache_functions.map,v
  retrieving revision 1.55
  retrieving revision 1.56
  diff -u -r1.55 -r1.56
  --- apache_functions.map  24 May 2002 17:37:08 -  1.55
  +++ apache_functions.map  15 Aug 2002 08:42:55 -  1.56
   -170,7 +170,6 
ap_server_root_relative | mpxs_ | SV *:p, fname=
   
   MODULE=Apache::Connection   PACKAGE=guess
  - ap_get_remote_host
   #XXX: thought this might be useful for protocol modules
   #however it is not exported on win32
   !ap_read_request
  
  
  
  1.76  +22 -0 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm
  
  Index: FunctionTable.pm
  ===
  RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v
  retrieving revision 1.75
  retrieving revision 1.76
  diff -u -r1.75 -r1.76
  --- FunctionTable.pm  23 Jun 2002 21:28:15 -  1.75
  +++ FunctionTable.pm  15 Aug 2002 08:42:55 -  1.76
   -4305,6 +4305,28 
   ]
 },
 {
  +'return_type' = 'char *',
  +'name' = 'mpxs_Apache__Connection_get_remote_host',
  +'args' = [
  +  {
  +'type' = 'PerlInterpreter *',
  +'name' = 'my_perl'
  +  },
  +  {
  +'type' = 'conn_rec *',
  +'name' = 'c'
  +  },
  +  {
  +'type' = 'int',
  +'name' = 'type'
  +  },
  +  {
  +'type' = 'apr_table_t *',
  +'name' = 'dir_config'
  +  }
  +]
  +  },
  +  {
   'return_type' = 'apr_size_t',
   'name' = 'mpxs_Apache__Filter_print',
   'attr' = [
  
  
  
  1.6   +18 -2 modperl-2.0/t/response/TestAPI/conn_rec.pm
  
  Index: conn_rec.pm
  ===
  RCS file: /home/cvs/modperl-2.0/t/response/TestAPI/conn_rec.pm,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- conn_rec.pm   11 Apr 2002 11:08:43 -  1.5
  +++ conn_rec.pm   15 Aug 2002 08:42:55 -  1.6
   -3,13 +3,15 
   use strict;
   use warnings FATAL = 'all';
   
  +use Apache::TestUtil;
   use Apache::Test;
   
   use Apache::RequestRec ();
   use Apache::RequestUtil ();
   use Apache::Connection ();
   
  -use Apache::Const -compile = 'OK';
  +use Apache::Const -compile = qw(OK REMOTE_HOST REMOTE_NAME
  +REMOTE_NOLOOKUP REMOTE_DOUBLE_REV);
   
   #this test module is only for testing fields in the conn_rec
   #listed in apache_structures.map
   -19,7 +21,7 
   
   my $c = $r-connection;
   
  -plan $r, tests = 15;
  +plan $r, tests = 22;
   
   ok $c;
   
   -56,6 +58,20 
   #input_filters
   #output_filters
   #remain
  +
  +# Connection utils (XXX: move to conn_utils.pm?)
  +
  +# $c-get_remote_host
  +ok $c-get_remote_host() || 1;
  +
  +for (Apache::REMOTE_HOST, 

cvs commit: modperl-2.0/t/response/TestAPI conn_rec.pm request_rec.pm server_rec.pm

2001-11-13 Thread dougm

dougm   01/11/13 10:40:01

  Modified:t/response/TestAPI conn_rec.pm request_rec.pm server_rec.pm
  Log:
  add some comments to the *_rec tests
  
  Revision  ChangesPath
  1.4   +6 -1  modperl-2.0/t/response/TestAPI/conn_rec.pm
  
  Index: conn_rec.pm
  ===
  RCS file: /home/cvs/modperl-2.0/t/response/TestAPI/conn_rec.pm,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- conn_rec.pm   2001/04/19 05:46:04 1.3
  +++ conn_rec.pm   2001/11/13 18:40:01 1.4
  @@ -5,6 +5,11 @@
   
   use Apache::Test;
   
  +use Apache::Const -compile = 'OK';
  +
  +#this test module is only for testing fields in the conn_rec
  +#listed in apache_structures.map
  +
   sub handler {
   my $r = shift;
   
  @@ -48,7 +53,7 @@
   #output_filters
   #remain
   
  -0;
  +Apache::OK;
   }
   
   1;
  
  
  
  1.13  +5 -0  modperl-2.0/t/response/TestAPI/request_rec.pm
  
  Index: request_rec.pm
  ===
  RCS file: /home/cvs/modperl-2.0/t/response/TestAPI/request_rec.pm,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- request_rec.pm2001/11/13 18:35:08 1.12
  +++ request_rec.pm2001/11/13 18:40:01 1.13
  @@ -8,6 +8,11 @@
   
   use Apache::Const -compile = 'OK';
   
  +#this test module is only for testing fields in the request_rec
  +#listed in apache_structures.map
  +#XXX: GloabalRequest test should be moved elsewhere
  +# as should $| test
  +
   sub handler {
   my $r = shift;
   
  
  
  
  1.7   +3 -3  modperl-2.0/t/response/TestAPI/server_rec.pm
  
  Index: server_rec.pm
  ===
  RCS file: /home/cvs/modperl-2.0/t/response/TestAPI/server_rec.pm,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- server_rec.pm 2001/11/13 18:35:08 1.6
  +++ server_rec.pm 2001/11/13 18:40:01 1.7
  @@ -9,6 +9,9 @@
   
   use Apache::Const -compile = 'OK';
   
  +#this test module is only for testing fields in the server_rec
  +#listed in apache_structures.map
  +
   sub handler {
   my $r = shift;
   
  @@ -61,9 +64,6 @@
   ok $s-limit_req_fields;
   
   Apache::OK;
  -
   }
   
   1;
  -
  -__END__
  
  
  



cvs commit: modperl-2.0/t/response/TestAPI conn_rec.pm

2001-04-18 Thread dougm

dougm   01/04/18 22:46:04

  Modified:t/response/TestAPI conn_rec.pm
  Log:
  remove tests for stuff moved out of conn_rec
  
  Revision  ChangesPath
  1.3   +1 -5  modperl-2.0/t/response/TestAPI/conn_rec.pm
  
  Index: conn_rec.pm
  ===
  RCS file: /home/cvs/modperl-2.0/t/response/TestAPI/conn_rec.pm,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- conn_rec.pm   2001/04/03 16:59:08 1.2
  +++ conn_rec.pm   2001/04/19 05:46:04 1.3
  @@ -10,7 +10,7 @@
   
   my $c = $r-connection;
   
  -plan $r, tests = 17;
  +plan $r, tests = 15;
   
   ok $c;
   
  @@ -33,10 +33,6 @@
   ok $c-aborted || 1;
   
   ok $c-keepalive || 1;
  -
  -ok $c-keptalive || 1;
  -
  -ok $c-keepalives || 1;
   
   ok $c-local_ip;