473,383 Members | 1,716 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

Testing PHP script using Test::Simple perl script

I have a perl logging module that sends log messages,
via post variables, to a simple PHP web app whose
purpose is to write them to a database table.

The module is organized in the standard Test::Simple
format, and as one of the unit tests I'd like to
include a message send (followed by a read of the
database table). But to make the tests self-contained
I'd prefer not to assume that the logging web app is
installed.

Can anyone suggest a way of running a PHP script,
possibly with an auxiliary script (?) to accept
post variables in interactive mode?

I thought of starting an Apache instance, using a
config file in the perl test directory and listening
on a non-standard port. But this, even if possible,
seems like using a hammer to crack a nut.

All constructive suggestions welcome...
Cheers

John R Ramsden
Jul 17 '05 #1
2 2330


maybe php-commandline?

http://www.php.net/manual/en/features.commandline.php

John Ramsden wrote:
I have a perl logging module that sends log messages,
via post variables, to a simple PHP web app whose
purpose is to write them to a database table.

The module is organized in the standard Test::Simple
format, and as one of the unit tests I'd like to
include a message send (followed by a read of the
database table). But to make the tests self-contained
I'd prefer not to assume that the logging web app is
installed.

Can anyone suggest a way of running a PHP script,
possibly with an auxiliary script (?) to accept
post variables in interactive mode?

I thought of starting an Apache instance, using a
config file in the perl test directory and listening
on a non-standard port. But this, even if possible,
seems like using a hammer to crack a nut.

All constructive suggestions welcome...
Cheers

John R Ramsden


Jul 17 '05 #2
Try using jmeter for testing php applications. It's great stuff.

http://www.phpbuilder.com/columns/bo...o20030610.php3

Jimmy
Jul 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Sam | last post by:
I would like to store html templates in a database. By using perl I would like to retrive the template ask the user to fill the template and store the whole file is template + the user data in a...
5
by: Mark Szlazak | last post by:
Apparently there is a textarea onscroll event bubbling bug in Firefox and Mozilla: https://bugzilla.mozilla.org/show_bug.cgi?id=229089 I'm trying to check for this bug with the following...
3
by: rahatekarabhijeet | last post by:
I want to create excel sheet using perl, i had installed all the necessary modules from CPAN. The perl program i taken from CPAN itself it is given below, #!/usr/bin/perl -w use warnings; use...
8
crazy4perl
by: crazy4perl | last post by:
hi all !!! i m new to perl. can anyone here please tell me how to communicate with websites using perl. do we need to use CGI for that or simply by using perl... simply i just wnt to fill some...
3
by: hakiran | last post by:
Hello all, I have been using Perl DBI the last 6months or so. I use it extensively with MySQL. But recently i tried to access Oracle DB with it and was having trouble. Any help would be...
1
by: nehaz | last post by:
can anyone tell me how can i configure a device from HTTP page using perl ? I am using following cmd to enter the http page use HTTP::Request; $req = HTTP::Request->new($httpRequestMethod =>...
7
by: kesava81 | last post by:
Hi, All, I am a perl novice..and I was wondering if there is anyway that a product installation can be automated using perl. Here is the scenario I am talking about. Take a product and...
3
by: poolboi | last post by:
hi guys, i dunno if this post should be in Perl or MySQL but i'm using Perl DBI to do manupilations now in MySQL i've got problem trying to input 2 arrays of data into 2 fields at the same...
0
by: koti688 | last post by:
Hi Mates, Can u Please tell me how to connect to Berkely Db using Perl . I have two files , i need to access these file using perl. These files with .db extension contains Keys and its...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.