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 Final Classes Laravel Package

nunomaduro/mock-final-classes

Dev-only helper that automatically enables mocking of final classes and methods in PHP tests. Works with PHPUnit, Pest, and ParaTest by removing final keywords on the fly via dg/bypass-finals—install with Composer and it just works.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture fit: Strong alignment with Laravel's testing ecosystem. Laravel projects commonly integrate third-party SDKs (e.g., AWS, Stripe) with final classes, and this package directly addresses testing challenges without modifying production code. It leverages PHPUnit's existing workflow, which is standard in Laravel applications.
Integration feasibility: High. Simple Composer installation (composer require --dev nunomaduro/mock-final-classes) with no additional bootstrapping required. However, the absence of a public repository complicates version compatibility checks and issue tracking.
Technical risk: Moderate. Bypassing final restrictions typically relies on PHP reflection or runtime hacks, which could break with PHP updates (

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