PHPackages                             yegor256/phprack - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. yegor256/phprack

ActiveLibrary[Testing &amp; Quality](/categories/testing)

yegor256/phprack
================

Light framework for automation of integration tests

1.1(12y ago)254.7k5[29 issues](https://github.com/yegor256/phprack/issues)[4 PRs](https://github.com/yegor256/phprack/pulls)BSD-3-ClausePHPPHP &gt;=5.2.0CI passing

Since Jan 28Pushed 1mo ago3 watchersCompare

[ Source](https://github.com/yegor256/phprack)[ Packagist](https://packagist.org/packages/yegor256/phprack)[ Docs](http://www.phprack.com)[ RSS](/packages/yegor256-phprack/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)DependenciesVersions (6)Used By (0)

Web Health Checking Framework
=============================

[](#web-health-checking-framework)

[![DevOps By Rultor.com](https://camo.githubusercontent.com/4959cfc227f8d49c0ac5c24255054c589999952e939c42f0d5a50f4985042022/687474703a2f2f7777772e72756c746f722e636f6d2f622f7965676f723235362f7068707261636b)](http://www.rultor.com/p/yegor256/phprack)

[![phing](https://github.com/yegor256/phprack/actions/workflows/phing.yml/badge.svg)](https://github.com/yegor256/phprack/actions/workflows/phing.yml)[![PDD status](https://camo.githubusercontent.com/de4ae269ead195a07d54456e5337ede73a2d57407debaa9ef25102fc1593011c/687474703a2f2f7777772e307064642e636f6d2f7376673f6e616d653d7965676f723235362f7068707261636b)](http://www.0pdd.com/p?name=yegor256/phprack)[![Hits-of-Code](https://camo.githubusercontent.com/26b4ac848cf4962e4e70db7f3f98777d957752cfd7f59dc98ddb5a9762aeb49b/68747470733a2f2f686974736f66636f64652e636f6d2f6769746875622f7965676f723235362f7068707261636b)](https://hitsofcode.com/view/github/yegor256/phprack)

Read about phpRack in [php|Architect June 2010](http://www.phparch.com/magazine/2010/june/): *Integration Testing with phpRack Framework*.

**phpRack** is a lightweight framework for integration test automation. Integration tests are checks that run in the production environment to validate that it is configured as expected. For example, your product is a web application that depends on PHP, Apache, MySQL, and the availability of YouTube, Flickr, and Google Maps APIs. Your product is tested with unit tests that use stubs for these services and components. When the product is deployed to production, you want to be sure that the services you need are configured and available. If they are not, you want a detailed notification before your end-users notice.

This is where phpRack helps. Add phpRack to your project and write a few tests. All these tests will be executed when requested and will produce a detailed report, both online and by email. It will save you a lot of time during deployment and later, during maintenance of your product.

To start using phpRack, follow these three steps:

- Upload phpRack library to your server
- Create `phprack.php` file in your `public_html` directory
- Create PHP integration tests in your rack-tests directory

Let's do them one by one:

Download [ZIP archive](https://github.com/yegor256/phprack/archive/master.zip)of phpRack and unpack it to `public_html/phpRack` or some other directory on your production server.

Create `phprack.php` in your project's public directory (see [full reference](https://github.com/yegor256/phprack/wiki/Bootstrap)), e.g.:

```
