/[Apache-SVN]/httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestRequest.pm
ViewVC logotype

Diff of /httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestRequest.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

--- httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestRequest.pm	2004/12/07 05:12:08	110079
+++ httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestRequest.pm	2004/12/07 05:19:39	110080
@@ -107,6 +107,21 @@ sub module2path {
     return $path;
 }
 
+sub module2url {
+    my $module   = shift;
+    my $opt      = shift || {};
+    my $scheme   = $opt->{scheme} || 'http';
+    my $path     = $opt->{path}   || module2path($module);
+
+    Apache::TestRequest::module($module);
+
+    my $config   = Apache::Test::config();
+    my $hostport = hostport($config);
+
+    $path =~ s|^/||;
+    return "$scheme://$hostport/$path";
+}
+
 sub user_agent {
     my $args = {@_};
 

 

infrastructure at apache.org
ViewVC Help
Powered by ViewVC 1.1.26