mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
fe5a5dc878
Summary: Changelog: [internal] following the recommendation in https://fb.workplace.com/groups/474291069286180/posts/6540719469309946 in order to unit test classes that use SurfaceHandler, we need to be able to mock it somehow - since the class is final we aren't able to do that. in this diff, we convert the function that we need to stub / listen to to a virtual function so we can mock it. the alternative is to keep this class final, and create another abstract interface that this will extend from. however, this class is quite large and that would have a lot more boilerplate and updation of callsites, so this simpler approach seems better. Reviewed By: sammy-SC Differential Revision: D30578928 fbshipit-source-id: 4a63396f049c44753986d15f1ac64332b2a8393a