Proper support for mocking Final classes
Author: ostroluckyCreated Dec 25, 2017Updated Sep 9, 2025
There is a good post which talks how to do this here https://markbakeruk.net/2017/11/19/extending-final-classes-and-methods-by-manipulating-the-ast/
Might be nice to have it in Mockery and remove current weird proxy workaround
There is also this https://github.com/dg/bypass-finals
Source: mockery/mockery