SHARE
Facebook X Pinterest WhatsApp

Testing Forms in PHP with SimpleTest

Written By
thumbnail
Web Webster
Web Webster
Mar 3, 2011

“Encouraging best practices within the PHP community through the
adoption of powerful tools such as Phing, PHPUnit and FirePHP was a
major focus of my 2010 contributions to Developer.com and
PHPBuilder.com. Much to my delight, interest in these articles was
so strong that I’ll be regularly returning to more
productivity-boosting utilities throughout 2011, starting with the
SimpleTest unit and Web testing framework.

“Although not as well known as PHPUnit, SimpleTest is an
immensely capable framework, having been adopted by popular PHP
projects including CakePHP and Drupal. In addition to offer a
complete suite of unit testing capabilities, SimpleTest is bundled
with an internal Web browser which you can use to automate the
navigation of your Web site and perform tests such as completing
and submitting Web forms much in the same way a typical user would.
In this tutorial, I’ll show you how to use SimpleTest to automate
these otherwise tedious tasks.

“Installing SimpleTest

“Download SimpleTest by heading over to its SourceForge page and
downloading the latest stable version. Once downloaded, unzip the
package to a convenient location and add its path to PHP’s
include_path. After restarting your Web server, you can make sure
SimpleTest is accessible from a PHP script by creating a PHP script
which contains the following code:”


Complete Story

thumbnail
Web Webster

Web Webster

Web Webster has more than 20 years of writing and editorial experience in the tech sector. He’s written and edited news, demand generation, user-focused, and thought leadership content for business software solutions, consumer tech, and Linux Today, he edits and writes for a portfolio of tech industry news and analysis websites including webopedia.com, and DatabaseJournal.com.

Recommended for you...

5 Best Free and Open Source Text Expander Tools
webmaster
Jun 13, 2025
Grafito: Systemd Journal Log Viewer with a Beautiful Web UI
Bobby Borisov
Jun 12, 2025
FreeBSD Wants to Know a Few Things
brideoflinux
May 11, 2025
NVK enabled for Maxwell, Pascal, and Volta GPUs
Kara Bembridge
May 1, 2025
Linux Today Logo

LinuxToday is a trusted, contributor-driven news resource supporting all types of Linux users. Our thriving international community engages with us through social media and frequent content contributions aimed at solving problems ranging from personal computing to enterprise-level IT operations. LinuxToday serves as a home for a community that struggles to find comparable information elsewhere on the web.

Property of TechnologyAdvice. © 2025 TechnologyAdvice. All Rights Reserved

Advertiser Disclosure: Some of the products that appear on this site are from companies from which TechnologyAdvice receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. TechnologyAdvice does not include all companies or all types of products available in the marketplace.