Unanswered unit test with mock objects

  • Saturday, February 13, 2010 7:43 PM
     
     
    0 vote down star

    Hello, Please take a look at the following article: http://www.kim-team.com/blog/2009/02/unit-testing-with-mock-objects/

    So there is an example of unit test with mock objects. As you can see, the test is written for GetPersonByID method. In the IPersonServices interface there is another method: List GetPersons();

    Can anyone tell me how should look a Test method on this service using mock objects? so in case of GetPersons, which has a List type.

    Thanks!

All Replies

  • Saturday, November 05, 2011 4:14 AM
     
     

    Hi,

    I think this article will help you to get basic understanding in mock.

    http://learningcsharpe.blogspot.com/2011/11/how-to-use-moq-library-for-your-unit.html

     

    thanks.