2

I am looking for some help with regards to SL4 and unit testing.

Is there a standard unit testing framework that exists? developed by microsoft?

I have found a number of ports for nunit and microsoft .net tests...

I would really appreciate any info with regards which framework to use.

While i am on it, a moq toolkit also exists for silverlight - any ideas ?

3 Answers 3

1

The Silverlight Toolkit includes a unit testing framework which is pretty powerful.

Also, you should consider the Microsoft Test Manager and its framework (if your development environment has access to it), as it contains great UI Test automation options that integrate with Silverlight as well as Web, WPF, and Win.Forms.

1

If you access to Visual Studio Feature Pack 2, you can play with the Coded UI framework for Automated Unit Test. See my video here.

1

I have had great success with NUnit and Moq with Silverlight. I like that with NUnit, the tests run outside the plug-in sandbox, so they run quickly and on CI machines.

2
  • Could you help me with that ? I can not figure it out how to run NUnit + Moq + SL in one package. Do you have any tutorial ? Links ?
    – Alex F
    May 16, 2012 at 8:30
  • @Jasper Hmmm. It has been a long time since I did it. You need the NUnit libraries built for Silverlight(code.google.com/p/nunit-silverlight) as well as the Moq built for Silverlight (code.google.com/p/moq/downloads/list). I also used TestDriven.net to run the tests. Good luck! May 18, 2012 at 10:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.