sigee commented on PR #276: URL: https://github.com/apache/commons-beanutils/pull/276#issuecomment-2317007428
I created a PoC commit [here](https://github.com/sigee/commons-beanutils/commit/fb1f2171e3afd66b01606a422d3ac7cc5309dc2c). Not my best work, but I thought about something like this. - I removed the final modifyer from LOG and created a constructor to inject my spy object. - In the test class I created 3 test cases - Basic case - Null case - toString() is overriden - I also created the LogSpy to check the parameters trace was called with. - I also created a child test bean where I override toString() For the spy Mockito would be great, because this hand-made spy feels wierd. But Mockito is not in the project and I'm not sure why. Anyway. What do you guys think? Is is a way to go or I just overengineering it? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
