Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4024660
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T10:44:57+00:00 2026-05-20T10:44:57+00:00

Is there a Perl module which can test the CGI output of another program?

  • 0

Is there a Perl module which can test the CGI output of another program? E.g. I have a program

x.cgi

(this program is not in Perl) and I want to run it from program

test_x_cgi.pl

So, e.g. test_x_cgi.pl is something like

#!perl
use IPC::Run3
run3 (("x.cgi"), ...)

So in test_x_cgi.pl I want to automatically check that the output of x.cgi doesn’t do stupid things like, e.g. print messages before the HTTP header is fully outputted. In other words, I want to have a kind of "browser" in Perl which processes the output. Before I try to create such a thing myself, is there any module on CPAN which does this?

Please note that x.cgi here is not a Perl script; I am trying to write a test framework for it in Perl. So, specifically, I want to test a string of output for ill-formedness.

Edit: Thanks

I have already written a module which does what I want, so feel free to answer this question for the benefit of other people, but any further answers are academic as far as I’m concerned.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T10:44:57+00:00Added an answer on May 20, 2026 at 10:44 am

    There is Test::HTTP. I have not used it, but seems to have an interface that fits your requirements.

    $test->header_is($header_name, $value [, $description]);
    

    Compares the response header
    $header_name with the value $value
    using Test::Builder-is>.

    $test->header_like($header_name, $regex, [, $description]);
    

    Compares the response header
    $header_name with the regex $regex
    using Test::Builder-like>.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Possible Duplicate: In Perl, how can I check from which module a given function
Possible Duplicate: In Perl, how can I check from which module a given function
I want to install File::Fetch, which is a core module in Perl 5.12, in
Are there conventions for function names when using the Perl Test::More or Test::Simple modules?
Are there any free Perl IDEs out there for Windows that have debugging capabilities,
I'm using Eclipse EPIC IDE to write some Perl CGI scripts which call some
I'm writing some tests in Perl which have a fair amount of set up.
I have been developing an internal framework which is designed with bunch of Perl
If all tables I want to delete from have the column gamer_id can i
How can I test that resource (file based cache for caching output of a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.