Unit testing: check values of the local variables within the private static void methods

57 Views Asked by At

I have a C# application that uses a lot of

1 ) private

2 ) static

3) return type of void

methods which is difficult to unit test.

I can use Microsoft.VisualStudio.TestTools.UnitTesting.PrivateType objects, and then use the InvokeStatic to call the aforementioned methods.

However, could someone please tell me if there is way to check value of the local variables within the aforementioned private static void methods?

0

There are 0 best solutions below