PHPackages                             react-parallel/test-pool - 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. react-parallel/test-pool

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

react-parallel/test-pool
========================

Pool meant for used in unit tests

05.7k↓33.3%[5 PRs](https://github.com/reactphp-parallel/test-pool/pulls)MakefileCI passing

Since Dec 20Pushed 2mo ago1 watchersCompare

[ Source](https://github.com/reactphp-parallel/test-pool)[ Packagist](https://packagist.org/packages/react-parallel/test-pool)[ RSS](/packages/react-parallel-test-pool/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (6)Used By (0)

test-pool
=========

[](#test-pool)

[![Continuous Integration](https://github.com/Reactphp-parallel/test-pool/workflows/Continuous%20Integration/badge.svg)](https://github.com/Reactphp-parallel/test-pool/workflows/Continuous%20Integration/badge.svg)[![Latest Stable Version](https://camo.githubusercontent.com/bf4379bcfcbcee088465a21b5caf7160f4b16aa7237169b4aab7292eaf0bad05/68747470733a2f2f706f7365722e707567782e6f72672f52656163742d706172616c6c656c2f746573742d706f6f6c2f762f737461626c652e706e67)](https://packagist.org/packages/React-parallel/test-pool)[![Total Downloads](https://camo.githubusercontent.com/c228781a21a4d7ffb031ad493118c73e039f0e9753e8d23916baab1290118198/68747470733a2f2f706f7365722e707567782e6f72672f52656163742d706172616c6c656c2f746573742d706f6f6c2f646f776e6c6f6164732e706e67)](https://packagist.org/packages/React-parallel/test-pool)[![Code Coverage](https://camo.githubusercontent.com/be3d6cdd7705128424e2c6ccf7f9abbd94fe53f740b5b94369a8bbbb2906c269/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f52656163747068702d706172616c6c656c2f746573742d706f6f6c2f6261646765732f636f7665726167652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/Reactphp-parallel/test-pool/?branch=master)[![Type Coverage](https://camo.githubusercontent.com/31c6088f498bd27b4e9e3fd56b82285fa1e977297ff3390fbc64829f9a463a4d/68747470733a2f2f73686570686572642e6465762f6769746875622f52656163747068702d706172616c6c656c2f746573742d706f6f6c2f636f7665726167652e737667)](https://shepherd.dev/github/Reactphp-parallel/test-pool)[![License](https://camo.githubusercontent.com/39582b3c6d1841e4ed01222a49334ec89339800ca38d73fadf7aa18558bf8a9a/68747470733a2f2f706f7365722e707567782e6f72672f52656163742d706172616c6c656c2f746573742d706f6f6c2f6c6963656e73652e706e67)](https://packagist.org/packages/React-parallel/test-pool)

Pool meant for used in unit tests

Install
-------

[](#install)

To install via [Composer](http://getcomposer.org/), use the command below, it will automatically detect the latest version and bind it with `~`.

```
composer require react-parallel/test-pool

```

Usage
-----

[](#usage)

The following example will spin up a thread with a 1 second TTL clean up policy. Meaning that threads are kept around for 1 second waiting for something to do before closed. It then runs a closure in the thread that will wait for one second before returning an message. Upon receiving that message the mean thread will echo out that message before closing the pool;

```
use React\EventLoop\Factory;
use ReactParallel\EventLoop\EventLoopBridge;
use ReactParallel\Pool\test\Direct;

$test = new Direct();
$test->run(function () {
    sleep(1);

    return 'Hoi!';
})->then(function (string $message) use ($test) {
    echo $message, PHP_EOL;
    $test->close();
});
```

License
-------

[](#license)

Copyright 2025 [Cees-Jan Kiewiet](http://wyrihaximus.net/)

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance57

Moderate activity, may be stable

Popularity21

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity18

Early-stage or recently created project

 Bus Factor1

Top contributor holds 62.5% 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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/147145?v=4)[Cees-Jan Kiewiet](/maintainers/WyriHaximus)[@WyriHaximus](https://github.com/WyriHaximus)

---

Top Contributors

[![WyriHaximus](https://avatars.githubusercontent.com/u/147145?v=4)](https://github.com/WyriHaximus "WyriHaximus (20 commits)")[![reactphp-parallel-renovate-runner[bot]](https://avatars.githubusercontent.com/u/56447449?v=4)](https://github.com/reactphp-parallel-renovate-runner[bot] "reactphp-parallel-renovate-runner[bot] (12 commits)")

### Embed Badge

![Health badge](/badges/react-parallel-test-pool/health.svg)

```
[![Health](https://phpackages.com/badges/react-parallel-test-pool/health.svg)](https://phpackages.com/packages/react-parallel-test-pool)
```

###  Alternatives

[phpspec/prophecy

Highly opinionated mocking framework for PHP 5.3+

8.5k551.7M682](/packages/phpspec-prophecy)[brianium/paratest

Parallel testing for PHP

2.5k118.8M754](/packages/brianium-paratest)[beberlei/assert

Thin assertion library for input validation in business models.

2.4k96.9M570](/packages/beberlei-assert)[mikey179/vfsstream

Virtual file system to mock the real file system in unit tests.

1.4k108.0M2.7k](/packages/mikey179-vfsstream)[orchestra/testbench

Laravel Testing Helper for Packages Development

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

Specification-oriented BDD framework for PHP 7.1+

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

PHPackages © 2026

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