About

I am a software developer in Seattle, building a new AI software company.

Ads

May 2008

Sun Mon Tue Wed Thu Fri Sat
        1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31

Recent Posts

Ads


« Code and Data | Main | Static Analysis Tools at the Summit »

March 17, 2007

Parameterized Unit Tests

Andrew Stopford wrote about a Microsoft Research technology called parameterized testing being developed on a project called Pex (Program EXploration). Pex is described as an…

…intelligent assistant to the programmer. By automatically generating unit tests, it allows [one] to find bug early. In addition, it suggests to the programmer hot to fix the bugs.

In addition to specifications, I have been thinking since last spring about how I could better integrate my software with unit-testing. While I am not planning on building a dedicated system like Pex, one common trait that my system may have with Pex is the ability to symbolically analyze a function with unspecified parameters. 

Some of the changes that I had been considering included:

  • Recognizing calls to the various unit-testing frameworks such as Assert.IsTrue.
  • Accepting test methods containing parameters.
  • Presenting an NUnit style tree-view interface.

In addition, NStatic would not actually cause any external side-effects to the environment, which may or may not be a benefit. Also, there may also be some cross-pollenation and integration with the specifications work post-V1.

It’s not entirely clear to me at the moment what additional value the last two bullet points have over just performing a regular scan over the codebase (and/or using specifications): Automatic calls to Setup and Teardown? More structured tests? Exploring specific scenarios?

These are just some of my thoughts for the long-term future of my product. None of these features are coming out in the first version.

TrackBack

TrackBack URL for this entry:
http://www.typepad.com/t/trackback/5190/17014678

Listed below are links to weblogs that reference Parameterized Unit Tests:

Comments

Interested in using parameterized test for web testing see my post at http://blog.incisif.net/2007/05/11/parameterized-test.aspx

Post a comment

If you have a TypeKey or TypePad account, please Sign In