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

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

psr-mock/http-message-implementation
====================================

Lightweight PSR-7 HTTP Message implementations provider tailored to simplify mocked testing.

1.0.1(2y ago)036.8k↑47.8%13MITPHPPHP ^8.1

Since Mar 27Pushed 2y ago1 watchersCompare

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

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

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

[![codecov](https://camo.githubusercontent.com/28c9043c461ac397c6fb5e3afdd63c6eeeb5caf9d30950552a20630a7e9edaba/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f7073722d6d6f636b2f687474702d6d6573736167652d696d706c656d656e746174696f6e)](https://codecov.io/gh/psr-mock/http-message-implementation) [![packagist](https://camo.githubusercontent.com/76fef2dc70c0c7f6211c53ca536f61948006156c3bf1bd1b511de4c565779492/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7073722d6d6f636b2f687474702d6d6573736167652d696d706c656d656e746174696f6e)](https://packagist.org/packages/psr-mock/http-message-implementation) ![status](https://camo.githubusercontent.com/7af636af91e866e1e8c5c05550daf1889896e293db71d27d1a02b2fb439f925f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f636865636b732d7374617475732f7073722d6d6f636b2f687474702d6d6573736167652d696d706c656d656e746174696f6e2f312e78) ![license](https://camo.githubusercontent.com/60743e2196dae46c0ff55b50e5ef71eb351efd363bd1bf34853117208629f7a4/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f7073722d6d6f636b2f687474702d6d6573736167652d696d706c656d656e746174696f6e)

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-message-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

Popularity29

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 (39 commits)")

---

Tags

http-message-implementationmockingpsrpsr-7testingpsrpsr-7testingmockinghttp-message-implementation

###  Code Quality

TestsPest

Static AnalysisPHPStan, Psalm, Rector

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

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

```
[![Health](https://phpackages.com/badges/psr-mock-http-message-implementation/health.svg)](https://phpackages.com/packages/psr-mock-http-message-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)[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)
