Test a public method which calls a private method using NUnit
问题 I have a public method in a class that internally calls a particular private method within that class. It looks something like this : public class MyClass : IMyClassInterface { public List<int> MyMethod(int a, int b) { MyPrivateMethod(a, b, ref varList, ref someVal); } private void MyPrivateMethod(int a, int b, ref List<int> varList, ref double someval) { } } Now, I basically want to test this public method using NUnit. I am using NMock 2.0 for mocking. How do I do it? Since, it internally