Re: Dynamically Defining Tests from Config File
Michael Reppy <[email protected]>
| Newsgroups | gmane.comp.windows.dotnet.nunit.user |
|---|---|
| Message-ID | <[email protected]> |
Our very simple solution to this is to have one 'test'. In which, we loop through the parameters and feed the data into a helper method which is invoked inside a try/catch. the helper method is written like a unit tests with all the asserts one would want to use. the loop catches any asserts, writing the message to a StringBuilder. After the loop, if the StringBuilder has any length, it calls Assert.Fail. I think this nothing more than just restating what Charlie said, but we have found this useful to find a way to catch all the errors in one run. -Mikey On Dec 1, 2007, at 8:15 AM, Charlie Poole wrote: > Hi Brad, > >> Your description sounds like you are doing acceptance or >> integration testing, rather than developer testing. > > It initially sounded that way to me as well, but on further > explanation, it seemed like he just needed a cleaner way > to create multiple developer tests. > > I guess that parameterized tests are a feature that may > be needed independent of the particular purpose of the > tests. We'll definitlely have them in 3.0, but I'm not > sure about 2.4.x. One approach would be to choose a syntax > that works well with the current add-in design. > > I'll think about it, but if anyone is already working > on a solution, let me know. > > Charlie > > > > ---------------------------------------------------------------------- > --- > SF.Net email is sponsored by: The Future of Linux Business White Paper > from Novell. From the desktop to the data center, Linux is going > mainstream. Let it simplify your IT future. > http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4 > _______________________________________________ > Nunit-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/nunit-users ------------------------------------------------------------------------- SF.Net email is sponsored by: The Future of Linux Business White Paper from Novell. From the desktop to the data center, Linux is going mainstream. Let it simplify your IT future. http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4