This article explains basics of unit testing and whether its mandate to be followed or not

Unit Testing: Basics, Mandate or Optional, to Follow (c-sharpcorner.com)