Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Mock Client Laravel Package

php-http/mock-client

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.

View on GitHub
Deep Wiki
Context7
1.6.1
  • Fix warnings with PHP 8.4.
1.6.0

Fixed

  • We actually did fallback to the legacy message factory discovery so 1.5.2 is broken. Changed to use PSR 17 factory discovery. If you allow the composer plugin of php-http/discovery, things will work out of the box. When disabled and you do not have a PSR-17 factory installed, you will need to explicitly require one, e.g. nyholm/psr7.
1.5.2

Broken, use 1.6.0 instead

Removed

  • Removed dependency on php-http/message-factory as the mock client does not use it.
1.5.1

Added

  • Allow psr/http-message version 2
  • Build with PHP 8.1 and 8.2
1.5.0

Changed

  • Provide psr/http-client-implementation
  • Drop support for php-http/httplug: 1.* to be sure to implement a version of the client interface that implements the PSR.
1.4.1

Fixed

  • Support PHP 7.4 and 8.0
1.4.0

Added

  • Support for the PSR-17 response factory

Changed

  • Drop support for PHP 5 and 7.0
  • Consistent implementation of union type checking

Fixed

  • reset() should not trigger setDefaultException error condition
1.3.1

Fixed

  • reset() also resets conditionalResults
1.3.0

Added

  • Conditional mock functionality
1.2.0

Added

  • Support for HTTPlug 2.0.
  • Support for php-http/client-common 2.0.
1.1.0

Added

  • Default response functionality
  • Default exception functionality
  • getLastRequest method
1.0.1

Fixed

  • php-http/client-common minimum dependency
1.0.0

Stable release with no changes since 0.3

0.3.0

Added

  • Support for custom MessageFactory

Changed

  • Updated dependencies
0.2.0

Changed

  • Updated dependencies
0.1.1
0.1.0

Added

  • Initial release
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport