PHPackages                             psr-mock/http-factory-implementation - 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. psr-mock/http-factory-implementation

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

psr-mock/http-factory-implementation
====================================

Lightweight PSR-17 HTTP Factory implementation provider tailored to simplify mocked testing.

1.0.1(2y ago)036.3k—8.7%3MITPHPPHP ^8.1

Since Mar 27Pushed 2y ago1 watchersCompare

[ Source](https://github.com/psr-mock/http-factory-implementation)[ Packagist](https://packagist.org/packages/psr-mock/http-factory-implementation)[ Docs](https://github.com/psr-mock/http-factory-implementation)[ RSS](/packages/psr-mock-http-factory-implementation/feed)WikiDiscussions 1.x Synced 1mo ago

READMEChangelog (2)Dependencies (12)Versions (3)Used By (3)

**Lightweight mocking library for [PSR-17 HTTP Factory](https://www.php-fig.org/psr/psr-17/) and [PSR-7 HTTP Message](https://www.php-fig.org/psr/psr-7) implementations, tailor-made to help you create test suites that are easier to write and maintain.**

[![codecov](https://camo.githubusercontent.com/657a6066445a9d2287864724305b0b190181fcc70f39ddd20628653d792c6ad9/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f7073722d6d6f636b2f687474702d666163746f72792d696d706c656d656e746174696f6e)](https://codecov.io/gh/psr-mock/http-factory-implementation) [![packagist](https://camo.githubusercontent.com/8ba9bb5d74f72acad4ba0819e6d62a3c5b99d7b5b18bfbf9455ddb68e1080ab5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7073722d6d6f636b2f687474702d666163746f72792d696d706c656d656e746174696f6e)](https://packagist.org/packages/psr-mock/http-factory-implementation) ![status](https://camo.githubusercontent.com/dc8cd43f26647e2cc9d1e51babb990e19f22f42e0bb2ef24e359b04bec14db4c/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f636865636b732d7374617475732f7073722d6d6f636b2f687474702d666163746f72792d696d706c656d656e746174696f6e2f312e78) ![license](https://camo.githubusercontent.com/b99abef91cbab70fbf0e2f871f45434d1f25d1c63f3d467af3ff8e447cfca454/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f7073722d6d6f636b2f687474702d666163746f72792d696d706c656d656e746174696f6e)

This library is primarily intended for use in libraries like SDKs that consume PSR implementations without requiring hard dependencies on specific libraries. The library mocks a real-world implementation and strictly adheres to PSR specifications, enabling you to create test suites that are easier to write and maintain. The library also exposes a robust developer API to help you debug and fix test failures substantially faster.

This package is part of the [PSR Mock](https://github.com/psr-mock) suite of mocking libraries.

Requirements
------------

[](#requirements)

- PHP 8.1+
- Composer 2.0+

Installation
------------

[](#installation)

```
composer require --dev psr-mock/http-factory-implementation
```

Only install this library as a development dependency (`--dev`). It's not built for use in production environments.

---

This library is not produced or endorsed by, or otherwise affiliated with, the PHP-FIG.

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity28

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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 ~172 days

Total

3

Last Release

805d ago

PHP version history (2 changes)1.0.0PHP ^8.0

1.0.1PHP ^8.1

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3093?v=4)[Evan Sims](/maintainers/evansims)[@evansims](https://github.com/evansims)

---

Top Contributors

[![evansims](https://avatars.githubusercontent.com/u/3093?v=4)](https://github.com/evansims "evansims (23 commits)")

---

Tags

http-factory-implementationhttp-message-implementationmockingpsrpsr-17testingpsrtestingmockingpsr-17http-factory-implementation

###  Code Quality

TestsPest

Static AnalysisPHPStan, Psalm, Rector

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/psr-mock-http-factory-implementation/health.svg)

```
[![Health](https://phpackages.com/badges/psr-mock-http-factory-implementation/health.svg)](https://phpackages.com/packages/psr-mock-http-factory-implementation)
```

###  Alternatives

[dg/bypass-finals

Removes final keyword from source code on-the-fly and allows mocking of final methods and classes

57026.3M456](/packages/dg-bypass-finals)[phpro/http-tools

HTTP tools for developing more consistent HTTP implementations.

28137.8k](/packages/phpro-http-tools)[quizlet/hammock

Hammock is a stand-alone mocking library for Hacklang.

27445.5k](/packages/quizlet-hammock)[janmarek/mockista

Mockista is library for mocking, which I've written, because I find mocking in PHPUnit awful.

29221.0k28](/packages/janmarek-mockista)[aeris/guzzle-http-mock

A mock library for verifying requests made with the Guzzle Http Client, and mocking responses.

2613.1k1](/packages/aeris-guzzle-http-mock)[imdhemy/es-testing-utils

Elasticsearch Testing utils

1149.8k](/packages/imdhemy-es-testing-utils)

PHPackages © 2026

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