Re: SuiteAttribute, RowTest and IterativeTest

"Charlie Poole" <[email protected]>
Newsgroups gmane.comp.windows.dotnet.nunit.devel
Message-ID <00bf01c883a9$fc476c30$6501a8c0@ferrari>
Hi Kelly, 

> >  SuiteAttribute is a hold-over from an older style of framework.
> >  NUnit 1.x got the idea from the original JUnit. NUnit 2.x  
> > discouraged its use, since we added automatic suite 
> creation  based on 
> > the namespace hierarchy.
> >
> >  Some people use it to create arbitrary combinations of tests  that 
> > can be loaded from the command line using the /fixture  option. In 
> > fact, this was the original and only purpose of  the 
> /fixture option - 
> > we changed it so it would accept  normal test fixtures and then 
> > namespaces.
> >
> >  Mostly, it's of historical interest but it did establish 
> the  pattern 
> > that we only call static methods at test load time.
> 
> So, would it possibly be deprecated in 3.0?

Could be.
 
> As for the pattern that we only call static methods at test 
> load time, I think that might have to change as we go towards 
> a full Theory implementation.

I guess that remains to be seen - bear in mind that I'm only
talking about user fixtures here. Although they shouldn't,
users often write test fixtures that create strange side
effects in their constructors - it's really weird when a
large machine in the corner starts up simply because you 
looked at the structure of the tests. I saw that happen
in one shop, back when there was an error in NUnit causing
the instance to be created too early.

So, if we are going to create any user-instances at load
time, I would rather they be some other object than the
test fixture class.

Charlie
 
> -Kelly
> 



-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.