Register   |  Login
You are hereArticles
 Article Details
Unit test case generation with Pex

Writing unit test cases with better code coverage have become so easy with Pex(Program EXploration) tool. An excellent white box unit test code generator.

Few days ago i was asked to write unit tests for the code whatever we have written so far.

When i was writing unit tests by using microsoft test project,  one of my collegues suggested why dont you try Pex.

Pex is a tool for generating unit test cases for dot net targeted code from microsoft research team. It analyzes the thoroughly and generates the code excellently.

You need to have Visual Studio Team System 2008(VSTS 2008) installed in you machine to use this. You can download Pex from microsoft website. Currently only academic version of Pex is available for VSTS 2008. Commercial version of pex is available only for VSTS 2010.

Using Pex generating test cases are very easy. Just select a project or class or  method on which unit test cases need to be written, right click the mouse and click on Run Pex Explorations, thats it. You are done. Pex would write code for you. Pex also writes the bug fixes some time :).

The code coverage with the pex tool is almost 100 percent.

You can find more information on this tool at research.microsoft.com/en-us/projects/Pex/

 


Written By: Kumaravel
Date Posted: 1/10/2009
Number of Views: 951


Comments
lu juan Says:
4/5/2011 5:24:49 PM

My favorite part of the suite is Microsoft Office 2010 . You can use it like a fancy clipboard, but Office 2010 is much more powerful and useful.So, I'm forced to pay for an upgrade to Microsoft Office that I did not want.For the price, you can't go wrong with Outlook 2010 Home & Student. And, I may or may not be able to use the Product Key on the package I purchased to activate only Word, Excel, Microsoft outlook 2010PowerPoint and OneNote, the programs I thought I was buying. The only answer was to go to MS Office, or have everyone else in the world switch to Office 2007 .The instructions on the Microsoft website for activating Office imply that the full Microsoft Office 2007 Professional suite is the only version eligible for proper licensing.


You must be logged in to submit a comment.

Return