Hi there,
I want to test a private static method and I simply do not find a way to do it. :(
The setup is an extension class which implements a couple of extension methods and these extension methods use private (to the extension class) methods to accomplish there jobs. And I want to test them. However some of which are generic and return a value. And I want to test the returned value.
Just to show the general idea:
public static class Extensions
{
public static DoSomting (this foo, int x)
{
DoSomethingElse<int> (x);
return x*2;
}
// this method shall be tested and the return value shall be checked
private static T DoSomethingElse<T> (T x)
{
if(typeof(t)==typeof(int))
return x*2;
return default(T)
}
}
I have searched the documentation and was not able to find help. :(
Could anyone give me a hint?
Thank's in advance.
mph