perl-modperl-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject cvs commit: modperl-2.0/ModPerl-Registry/t/cgi-bin cgi.pl
Date Mon, 07 Apr 2003 07:55:41 GMT
stas        2003/04/07 00:55:40

  Added:       ModPerl-Registry/t cgi.t
               ModPerl-Registry/t/cgi-bin cgi.pl
  Log:
  add a new simple test to test CGI.pm under MP::Registry
  
  Revision  Changes    Path
  1.1                  modperl-2.0/ModPerl-Registry/t/cgi.t
  
  Index: cgi.t
  ===================================================================
  use strict;
  use warnings FATAL => 'all';
  
  use Apache::Test;
  use Apache::TestUtil;
  use Apache::TestRequest qw(GET);
  
  plan tests => 2;
  
  my $url = "/registry/cgi.pl";
  my $res = GET $url;
  
  ok t_cmp(
      qr{^text/html},
      $res->header('Content-type'),
      "test 'Content-type header setting"
     );
  
  ok t_cmp(
      '<b>done</b>',
      lc($res->content),
      "test body"
     );
  
  
  
  1.1                  modperl-2.0/ModPerl-Registry/t/cgi-bin/cgi.pl
  
  Index: cgi.pl
  ===================================================================
  use CGI qw/:standard :html3/;
  
  print header(-type=>'text/html');
  print b("done");
  
  
  

Mime
View raw message