.Net Tips — using InternalsVisibleTo attribute to help testing non-public methods

Oh, the Pain! For a long time, unit test­ing non-pub­­lic meth­ods in C# has been a pain in the back side. In order to test a non-pub­­lic method (most like­ly pri­vate meth­ods) you have a num­ber of choic­es each with an unde­sired effect: The eas­i­est way out is to make the meth­ods pub­lic. How­ev­er, this …

.Net Tips — using Inter­nalsVis­i­ble­To attribute to help test­ing non-pub­lic meth­odsRead More »

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.