tomb1n0/guzzle-mock-handler
Lightweight mock handler for Guzzle to fake HTTP responses in tests. Queue responses, simulate status codes, headers, and body content, and inspect requests without making real network calls—useful for unit/integration testing of API clients.
|
Package
|
Score
|
Description
|
Stars
|
Likes
|
Forks
|
Downloads
|
Issues
|
Score
|
Opportunity
|
License
|
Last Release
|
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| guzzle/plugin-mock | 0.87 | guzzle/plugin-mock provides a mock plugin for Guzzle, letting you queue predefined responses and simulate HTTP requests during testing. Useful for isolating API clients, reproducing edge cases, and running fast, reliable unit tests without real network calls. | 3 | 3 | 0 | 586 | 0 | 0.0 | 30.0 | — | — | |
| mockery/mockery | 0.87 | Mockery is a flexible PHP mock object framework for unit testing with PHPUnit, PHPSpec, or any other testing framework. It offers a succinct, human-readable DSL for defining test doubles and integrates easily as a drop-in alternative to PHPUnit's mocking library. | 10,724 | 10,808 | 470 | 19M | 89 | 84.3 | 77.1 | BSD-3-Clause | 2 months ago | |
| guzzle/client-integration-tests | 0.87 | Integration test suite for Guzzle HTTP client implementations. Provides shared fixtures and tests to verify PSR-7/PSR-18 behavior, compatibility, and edge cases across adapters and transports. Designed for package maintainers validating clients. | 0 | — | 0 | — | 0 | 0.0 | — | MIT | — | |
| guzzlehttp/guzzle-services | 0.87 | Build SDK-style API clients with service descriptions: map named operations and parameters to HTTP requests and transform responses into result data, instead of hand-writing request serializers for every endpoint. | 254 | 256 | 79 | 200K | 0 | 29.1 | 45.8 | MIT | 2 months ago | |
| psr-mock/http | 0.86 | psr-mock/http is a tiny PHP package for mocking PSR-7 HTTP messages in tests. Create predictable request/response objects without a full HTTP client, helping you unit test middleware, clients, and services with minimal setup. | 1 | 1 | 0 | 1K | 0 | 0.6 | 39.5 | MIT | 2 years ago | |
| requests/test-server | 0.86 | Minimal PHP HTTP test server used by the Requests for PHP library to run its automated CI test suite. Not intended as a standalone server; install via Composer (requires Composer 2.2+) if needed for local testing. | 2 | 3 | 3 | 408 | 1 | 0.3 | 33.3 | — | — | |
| php-mock/php-mock | 0.86 | Mock built-in PHP functions like time() or rand() in tests by leveraging PHP’s namespace fallback: define namespaced replacements for unqualified calls. Works in non-global namespaces; supports common test frameworks via integrations (e.g., PHPUnit). | 370 | 375 | 19 | 726K | 3 | 13.0 | 47.8 | WTFPL | 9 months ago | |
| guzzlehttp/test-server | 0.85 | Guzzle Test Server is a dev-only testing helper that starts a local Node.js HTTP server, letting PHP tests queue responses and inspect received requests for handler and integration tests. | 14 | 14 | 2 | 23K | 0 | 23.4 | 51.4 | MIT | 2 weeks ago | |
| tmarsteel/mockery-callable-mock | 0.85 | Create Mockery-friendly callable/function mocks in PHP. Set expectations (with args, counts), return values, stubs, and verify calls or non-calls. Can also wrap a real callable to spy while still invoking it. Requires PHP 7+. | 1 | 1 | 1 | 1K | 0 | 0.9 | 39.7 | — | 9 years ago | |
| rtheunissen/guzzle-log-middleware | 0.85 | Lightweight Guzzle middleware for logging HTTP requests and responses. Capture method, URL, headers, body, status and timing, and route logs through PSR-3/Monolog with configurable formats, levels, and filtering—ideal for debugging and auditing API traffic. | 82 | 85 | 17 | 40K | 1 | 1.0 | 37.0 | — | — | |
| psr-mock/http-client-implementation | 0.85 | Tiny PSR-18 HTTP client implementation intended for mocking and testing. Provides a simple client you can plug into PSR-7/PSR-17 workflows to return predefined responses without real network calls. | 1 | 1 | 0 | 3K | 0 | 0.6 | 44.8 | MIT | 2 years ago | |
| php-http/mock-client | 0.85 | Mock HTTP client for HTTPlug/PHP-HTTP. Stores outgoing requests and returns queued responses or throws exceptions instead of making real network calls—ideal for unit tests of HTTP-dependent code. Install via Composer as a dev dependency. | 71 | 75 | 16 | 266K | 0 | 6.0 | 49.3 | MIT | 2 years ago | |
| guzzlehttp/promises | 0.85 | Guzzle Promises is a small PHP promise library that powers Guzzle's asynchronous requests. It provides promise chaining, synchronous waiting, cancellation, and helpers for coordinating groups of promises. Install it directly when you need promise composition without the full HTTP client. | 7,705 | 7,749 | 132 | 18M | 2 | 57.1 | 55.8 | MIT | 2 weeks ago | |
| donatj/mock-webserver | 0.85 | Lightweight PHP mock web server for tests and local development. Spin up an HTTP server on a random port, enqueue canned responses, inspect received requests, and simulate endpoints reliably. Handy for integration tests without external services. | 141 | 142 | 22 | 72K | 5 | 17.6 | 42.3 | MIT | 8 months ago | |
| psr-mock/http-factory-implementation | 0.85 | Lightweight PSR-17/PSR-7 HTTP factory/message mock implementation for PHP 8.1+. Built for SDKs and libraries to test against PSR interfaces without hard deps, with strict PSR compliance and helpful debugging API. | 0 | 0 | 0 | 4K | 0 | 0.6 | 50.0 | MIT | 2 years ago | |
| caseyamcl/guzzle_retry_middleware | 0.85 | Guzzle Retry Middleware automatically retries Guzzle HTTP requests when servers return 429 or 503, or when requests time out. It honors Retry-After headers, backs off exponentially, supports configurable retry limits and callbacks, and drops into your handler stack with no setup. | 222 | 224 | 33 | 558K | 6 | 25.9 | 54.8 | MIT | 3 months ago | |
| mcustiel/phiremock-client | 0.85 | PHP client for Phiremock Server with a fluent API to define HTTP expectations, manage scenarios, and reset server state. Works with Guzzle 6 by default, or any PSR-18 HTTP client by overriding the factory for custom connections. | 16 | 16 | 9 | 11K | 1 | 17.1 | 43.6 | GPL-3.0 | 6 months ago | |
| guzzlehttp/retry-subscriber | 0.85 | A Guzzle subscriber that automatically retries failed HTTP requests using configurable strategies, including exponential backoff. Set retry limits, delays, and the exceptions or status codes that trigger a retry to make your Guzzle 6/7 API calls more resilient. | 61 | 58 | 15 | 974 | 0 | 0.4 | 11.9 | MIT | — | |
| guzzlehttp/command | 0.85 | Build higher-level web service clients on top of Guzzle by modeling operations as Commands and responses as Results. Includes a generic ServiceClient plus command middleware to map commands to PSR-7 requests and responses to structured results. | 115 | 119 | 21 | 175K | 0 | 23.8 | 50.5 | MIT | 2 months ago | |
| reecem/mocker | 0.84 | A lightweight Laravel-friendly mocking helper for PHP tests. Quickly define and swap mocks, set expectations, and control return values to simplify unit and feature testing. Designed to reduce boilerplate and keep test setup clean and readable. | 7 | 7 | 16 | 2K | 2 | 4.3 | 33.2 | MIT | 3 years ago |
How can I help you explore Laravel packages today?