A code health check should not determine the access level for your method.
When you create a private method, it is usually used to modulate your code, or possibly other refactoring. Unless it is an API that is open, it is not a candidate for unit testing in any way.
So, the question you should first ask is: βDo I need to expose B ()?β If the answer is still no, then the question of testing it becomes irrelevant.
A very useful link for unit testing approaches is Clean Codes .
source share