Hello,
I have few debates and I wonder how do you feel/think about testing <span style="text-decoration:underline
private classes ?
Why do you use private classes to begin with ? Would you consider using internals instead ?
Would you make it protected, and use a mock object to test it ?
Would you consider refactoring classes just so you can test them ? would you expose them ?
Would you consider using reflections in extreme cases ?
Is it even worth testing ? given that these classes affect directly the parent class ? and testing it might be sufficient.
It would be quite useful if some people can elaborate on this, and discuss different approaches to handle this.
Thank you.
<
Eyal, Regards. <br/>
<br/>
http://blog.eyalsh.net blog.eyalsh.net
View the full article
I have few debates and I wonder how do you feel/think about testing <span style="text-decoration:underline
private classes ?
Why do you use private classes to begin with ? Would you consider using internals instead ?
Would you make it protected, and use a mock object to test it ?
Would you consider refactoring classes just so you can test them ? would you expose them ?
Would you consider using reflections in extreme cases ?
Is it even worth testing ? given that these classes affect directly the parent class ? and testing it might be sufficient.
It would be quite useful if some people can elaborate on this, and discuss different approaches to handle this.
Thank you.
<
Eyal, Regards. <br/>
<br/>
http://blog.eyalsh.net blog.eyalsh.net
View the full article