Functions that rely on indirect input and output require test doubles to unit test. In Unity, test doubles are created using NSubstitute.
In this video, I demonstrate how to import that NSubstitute DLL and create unit tests for a generic class called Player.
● Source Code: GitHub - charlieamat/test-doubles-nsubstitute: Companion project to https://youtu.be/xSa2S-W7x48
● Principles of Solitary Unit Testing: Principles of Solitary Unit Testing
● Blog post: http://infalliblecode.com/use-nsubstitute-create-test-doubles-unity/