PHPackages                             peridot-php/peridot - 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. peridot-php/peridot

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

peridot-php/peridot
===================

Event driven BDD test framework for PHP 7.1+

1.19.0(9y ago)326194.6k↓31%28[7 issues](https://github.com/peridot-php/peridot/issues)[1 PRs](https://github.com/peridot-php/peridot/pulls)20MITPHPPHP &gt;=5.4CI failing

Since Oct 20Pushed 2y ago9 watchersCompare

[ Source](https://github.com/peridot-php/peridot)[ Packagist](https://packagist.org/packages/peridot-php/peridot)[ RSS](/packages/peridot-php-peridot/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (6)Versions (47)Used By (20)

[![Peridot logo](https://camo.githubusercontent.com/fbe0a9654097e97e7bfcae3ce03cae08f12a8b9adbfab9b923937bd241737038/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f70657269646f742f6d61737465722f6c6f676f2e706e67 "Peridot logo")](https://camo.githubusercontent.com/fbe0a9654097e97e7bfcae3ce03cae08f12a8b9adbfab9b923937bd241737038/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f70657269646f742f6d61737465722f6c6f676f2e706e67)

[![Packagist Version](https://camo.githubusercontent.com/7847a18d25fd8e67539c504ca9fe4110458634c8e7d80dee8ae90a8c132e730b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f70657269646f742d7068702f70657269646f742e7376673f7374796c653d666c61742d737175617265 "Packagist Version")](https://packagist.org/packages/peridot-php/peridot)[![Build Status](https://camo.githubusercontent.com/65d5155ff83aa6ee52f8c71f81d0fb7138a6120ea9bba577bf579839f4e063cd/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f70657269646f742d7068702f70657269646f742f6d61737465722e7376673f7374796c653d666c61742d737175617265 "Build Status")](https://travis-ci.org/peridot-php/peridot)[![HHVM Build Status](https://camo.githubusercontent.com/fbdbbc8395ac503d224ccacf0e3a588e948b146ff4f9070f0d9adba8df926b01/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6868766d2d7465737465642d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265 "HHVM Build Status")](https://travis-ci.org/peridot-php/peridot)[![Windows Build Status](https://camo.githubusercontent.com/de31ab2dd158dae39d0205cc712b8f6bc25e59e26ce29dc2806df10097d5b6d5/68747470733a2f2f696d672e736869656c64732e696f2f6170707665796f722f63692f70657269646f742f70657269646f742f6d61737465722e7376673f6c6162656c3d77696e646f7773267374796c653d666c61742d737175617265 "Windows Build Status")](https://ci.appveyor.com/project/peridot/peridot)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/6aa74009298af3fbc2c7a5c3029d5de49e49b341142b0ee4718b1305a33a506d/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f70657269646f742d7068702f70657269646f742e7376673f7374796c653d666c61742d737175617265 "Scrutinizer Code Quality")](https://scrutinizer-ci.com/g/peridot-php/peridot/?branch=master)[![Codecov Coverage](https://camo.githubusercontent.com/07dfe8da9864783f1ee2eed89329e26f4e740fb314ccb36e574388d876641174/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f70657269646f742d7068702f70657269646f742f6d61737465722e7376673f7374796c653d666c61742d737175617265 "Codecov Coverage")](https://codecov.io/gh/peridot-php/peridot)[![Gitter Chat](https://camo.githubusercontent.com/e4e66feb2980ed424f53dcbc0fbbedb6e78545ccf81477ba59e905a4417fd156/68747470733a2f2f696d672e736869656c64732e696f2f6769747465722f726f6f6d2f70657269646f742d7068702f6c6f6262792e7376673f7374796c653d666c61742d737175617265 "Gitter Chat")](https://gitter.im/peridot-php/lobby)

The highly extensible, highly enjoyable, PHP testing framework.

Read more at [peridot-php.github.io](http://peridot-php.github.io/) or head over to the [wiki](https://github.com/peridot-php/peridot/wiki).

Building PHAR
-------------

[](#building-phar)

Peridot's phar is built using [Box](https://github.com/box-project/). Once box is installed, the phar can be built using the following command from the project directory:

```
box build

```

Generating Peridot's documentation
----------------------------------

[](#generating-peridots-documentation)

Peridot API documentation is generated using [apigen](https://github.com/apigen/apigen). Once apigen is installed, run the following command from the project directory:

```
apigen generate

```

This will output documentation to the docs/ directory.

Running Peridot's tests
-----------------------

[](#running-peridots-tests)

Peridot's test suite can be run using Peridot:

```
$ bin/peridot

```

And a sample of output:

[![Peridot output sample](https://camo.githubusercontent.com/f843c4b62fb72afb2c7f213f5e2a3cb708d5f86ec567a73b648fd96395a2ccb7/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f70657269646f742f6d61737465722f6f75747075742d73616d706c652e706e67 "Peridot output sample")](https://camo.githubusercontent.com/f843c4b62fb72afb2c7f213f5e2a3cb708d5f86ec567a73b648fd96395a2ccb7/68747470733a2f2f7261772e6769746875622e636f6d2f70657269646f742d7068702f70657269646f742f6d61737465722f6f75747075742d73616d706c652e706e67)

Release
-------

[](#release)

We use [Robo](https://github.com/Codegyre/Robo) for releases.

```
robo release [version] [site-path]

```

using assert for expectations
-----------------------------

[](#using-assert-for-expectations)

Peridot sets `ASSERT_CALLBACK` via [assert\_options](http://php.net/manual/en/function.assert-options.php) in order to throw exceptions when using the native `assert` function. Peridot specs are considered passing if they don't throw an exception; if you are using `assert` for expectations and you find your specs are triggering false positives, you may need to update `zend.assertions` to `1` in your php.ini. This is set to `-1` by default in PHP 7+

If you aren't too keen on using `assert` for testing, there are a ton of assertion/expectation libraries out there. Anything that throws exceptions in response to a failed assertion will do. The [peridot-php](https://github.com/peridot-php) org has authored [Leo](https://github.com/peridot-php/leo), and this library offers a richer assertion vocabulary for testing.

###  Health Score

47

—

FairBetter than 94% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity51

Moderate usage in the ecosystem

Community39

Small or concentrated contributor base

Maturity71

Established project with proven stability

 Bus Factor1

Top contributor holds 78.9% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~19 days

Recently: every ~112 days

Total

44

Last Release

3407d ago

Major Versions

1.15.1 → 2.0.x-dev2015-05-17

PHP version history (3 changes)1.0.0PHP &gt;=5.4.0

2.0.x-devPHP &gt;=5.6.0

1.19.0PHP &gt;=5.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/f71e23eec19a24f64f37c622e76e725c9a580f83ff40c411da9bad97e0a49089?d=identicon)[brianium](/maintainers/brianium)

---

Top Contributors

[![brianium](https://avatars.githubusercontent.com/u/636651?v=4)](https://github.com/brianium "brianium (381 commits)")[![austinsmorris](https://avatars.githubusercontent.com/u/1616868?v=4)](https://github.com/austinsmorris "austinsmorris (70 commits)")[![ezzatron](https://avatars.githubusercontent.com/u/100152?v=4)](https://github.com/ezzatron "ezzatron (20 commits)")[![Radiergummi](https://avatars.githubusercontent.com/u/6115429?v=4)](https://github.com/Radiergummi "Radiergummi (5 commits)")[![ragboyjr](https://avatars.githubusercontent.com/u/1975857?v=4)](https://github.com/ragboyjr "ragboyjr (3 commits)")[![YuraLukashik](https://avatars.githubusercontent.com/u/4070636?v=4)](https://github.com/YuraLukashik "YuraLukashik (2 commits)")[![mrkrstphr](https://avatars.githubusercontent.com/u/164472?v=4)](https://github.com/mrkrstphr "mrkrstphr (1 commits)")[![loalf](https://avatars.githubusercontent.com/u/337904?v=4)](https://github.com/loalf "loalf (1 commits)")

---

Tags

bddphptestingphptestingBDDTDD

### Embed Badge

![Health badge](/badges/peridot-php-peridot/health.svg)

```
[![Health](https://phpackages.com/badges/peridot-php-peridot/health.svg)](https://phpackages.com/packages/peridot-php-peridot)
```

###  Alternatives

[mockery/mockery

Mockery is a simple yet flexible PHP mock object framework

10.7k497.0M23.6k](/packages/mockery-mockery)[codeception/codeception

All-in-one PHP Testing Framework

4.9k86.2M2.9k](/packages/codeception-codeception)[behat/behat

Scenario-oriented BDD framework for PHP

4.0k96.8M2.0k](/packages/behat-behat)[phpspec/phpspec

Specification-oriented BDD framework for PHP 7.1+

1.9k36.7M3.1k](/packages/phpspec-phpspec)[orchestra/testbench

Laravel Testing Helper for Packages Development

2.2k39.1M32.1k](/packages/orchestra-testbench)[orchestra/testbench-core

Testing Helper for Laravel Development

27043.7M310](/packages/orchestra-testbench-core)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
