FREEDOM251

Freedom251 › Property-Based Testing Tools

Eris

Free plan Self-hosted

Visit Eris Alternatives

Eris's own site

What Eris is

Eris is a free, self-hosted PHP library for property-based testing with PHPUnit. It generates input samples and checks them against properties defined for the system under test. When an assertion fails, it tries to shrink the generated input and reports the smallest failing value it finds. Documented generators cover scalar values, collections, composite values and domain data such as names, dates and strings matching regular expressions. Developers can set a pseudorandom seed to try to reproduce a run. Each forAll() call generates 100 values by default; iteration counts and test duration can be configured. The duration is approximate because the current iteration and any shrinking it triggers must finish before the run stops. Eris can also generate reproducible random data outside PHPUnit, including for other testing frameworks or scripts. The repository lists compatibility with PHP 8.1–8.4 and PHPUnit 10.x–13.x. Installation is through Composer as a development dependency, and the project is MIT licensed. Listeners can receive run events, while generic exceptions from a test callback interrupt the test rather than being shrunk.

Who it suits

Eris suits PHP developers who want property-based tests in PHPUnit or reproducible random data in another testing framework or script. It is most relevant when shrinking assertion failures and replaying generated cases matter.

What it does well

  • Generates 100 values by default for each forAll() call.
  • Attempts to shrink assertion failures.
  • A pseudorandom seed can help reproduce a run.
  • Generators include scalars, collections and domain data.
  • Can be used outside PHPUnit.

What to know first

  • A configured time limit is approximate.
  • Generic callback exceptions interrupt the test.
  • PHPUnit compatibility is listed for versions 10.x through 13.x.

Limits

Each forAll call runs 100 generated values by default. A configured duration is approximate because the current iteration and any shrinking must complete before the run stops.

Getting started

  1. Install PHP 8.1 through 8.4 and a compatible PHPUnit version
  2. Add Eris as a Composer development dependency
  3. Run composer require --dev giorgiosironi/eris
  4. Define properties and generated inputs in your tests
  5. Execute the tests with PHPUnit or another supported framework

Verdict

Eris provides a focused way to generate property-based test inputs and narrow assertion failures in PHP. Its approximate duration limit and exception behavior are important when configuring test runs.

Questions

What does Eris cost?

Eris is free and distributed under the MIT license.

Which PHP and PHPUnit versions are compatible?

The repository lists PHP 8.1 through 8.4 and PHPUnit 10.x through 13.x.

How is Eris installed?

Install it with Composer as a development dependency using composer require --dev giorgiosironi/eris.

Can Eris run without PHPUnit?

Yes. It can be used as a library for reproducible random data in other testing frameworks or scripts.

How many cases does it generate?

A forAll call generates 100 values by default, with configurable iteration counts or test duration.

What happens when an assertion fails?

Eris attempts to shrink the generated input and reports the simplest failing value it finds.

Facts from Eris's own pages

Compatibility
The repository lists support for PHP 8.1 through 8.4 and PHPUnit 10.x through 13.x. · github.com, 7 Oct 2026
Configurable runtime
The number of generated iterations and a test duration can be configured, though the duration is approximate because a running iteration and any shrinking must finish. · eris.readthedocs.io, 7 Oct 2026
Default sample size
By default, Eris runs 100 generated values for each forAll() call. · eris.readthedocs.io, 7 Oct 2026
Failure shrinking
When an assertion fails, Eris attempts to simplify the generated input and reports the simplest failing value it finds. · eris.readthedocs.io, 7 Oct 2026
Generated testing
It generates samples of inputs and runs them against properties defined for the system under test. · eris.readthedocs.io, 7 Oct 2026
Generators
Its documented generators cover scalar values, collections, composite values, and domain-based values such as names and dates. · eris.readthedocs.io, 7 Oct 2026
Input generators
Documented generators cover scalar values, collections, composite values, and domain data such as names, dates, and regex-matching strings. · eris.readthedocs.io, 7 Oct 2026
Installation
The README gives Composer as the installation method and shows the command composer require --dev giorgiosironi/eris. · github.com, 7 Oct 2026
License
The repository identifies the project as MIT licensed. · github.com, 7 Oct 2026
Listeners
Listeners can receive events during test runs, and documented examples collect generated-value frequencies or write progress logs. · eris.readthedocs.io, 7 Oct 2026
Maintainer
The project documentation credits Giorgio Sironi. · eris.readthedocs.io, 7 Oct 2026
Maker
The repository is under Giorgio Sironi’s GitHub account, whose profile lists Cambridge, UK. · github.com, 7 Oct 2026
Notable limit
The documentation says a configured time limit is approximate because the current iteration and any resulting shrinking must finish before the test stops. · eris.readthedocs.io, 7 Oct 2026
Outside PHPUnit
Eris can also be used as a library to generate reproducible random data in other testing frameworks or scripts. · eris.readthedocs.io, 7 Oct 2026
PHPUnit integration
Eris can be installed as a Composer development dependency and its examples can be run with PHPUnit. · eris.readthedocs.io, 7 Oct 2026
Purpose
Eris brings QuickCheck-style property-based testing to PHP and PHPUnit. · github.com, 7 Oct 2026
Reproducibility
When Eris is used outside PHPUnit, the documentation says reproducibility can be obtained by setting the ERIS_SEED environment variable. · eris.readthedocs.io, 7 Oct 2026
Runtime controls
A forAll call generates 100 values by default, and users can configure iteration counts or a test duration. · eris.readthedocs.io, 7 Oct 2026
Security and license
The GitHub repository identifies an MIT license; the opened maker pages do not state security certifications or compliance claims. · github.com, 7 Oct 2026
Shrinking caveat
Shrinking is performed for assertion failures, while generic exceptions from the test callback interrupt the test. · eris.readthedocs.io, 7 Oct 2026
Support
The project invites users to open GitHub issues for support and feature requests. · github.com, 7 Oct 2026
Supported versions
The repository README lists PHP 8.1–8.4 and PHPUnit 10.x–13.x as compatible versions. · github.com, 7 Oct 2026
Usage outside PHPUnit
Eris can be used outside PHPUnit as a library for reproducible random data generation, including in other testing frameworks or scripts. · eris.readthedocs.io, 7 Oct 2026

Where Eris stands on Freedom251

Look at these too