Re: Addin Error Reporting Issue

"Charlie Poole" <[email protected]>
Newsgroups gmane.comp.windows.dotnet.nunit.devel
Message-ID <002301c8701f$20aa06d0$6401a8c0@ferrari>
Hi Daniel, 

> Thanks for clearing all of that up.  As for the colours, mea 
> culpa.  I use TD.Net, which is part of my issue.

Ah... no colors then :-)
 
> Your explaination of the difference between Ignore and 
> Explicit makes perfect sense, but for various reasons, we 
> never use [Ignore].  If a test is marked as [Ignore] it is 
> impossible to force it to run without removing the [Ignore] 
> attribute.  This just seems dangerous to me, as I it opens 
> the door for accidentally checking code in without adding the 
> attribute back to the test, and thus breaking the build.  We 
> use Explicit in stead since it allows us to still run the 
> test, even if its just to test it.  Note, this same behaviour 
> is exhibited in TD.Net, and after talking to Jamie, I got the 
> impression he simply mimics the behaviour of nunit.exe (as he 
> should). 

TD.Net uses NUnit to run the tests. Just not the Gui.

I have been thinking about letting Ignore work like Explicit
with the sole exception being the reporting. I've also been
thinking about coloring poorly formed tests (bad sig, etc)
red, rather than yellow.

> I understand that ExplicitAttribute and IgnoreAttribute have 
> different reasons.  Thanks for pointing that out to me.  I 
> would like to make the following requests / suggestions:
> 
> 1)  Allow Ignored tests to be run through the runner without 
> removing the attribute.  Jamie will likely follow suit.

Yes, I think that's a good idea. Since TD.Net runs real NUnit,
unlike some other addins, it will follow automatically. :-)

> 2)  If you do that, I open the question again of why have 
> both, but I do see the reason.  I guess just think about it.
> 
> 3)  More clearly document the differences.

Hmmm... I think the doc pages do describe the diffs, but I'll 
check.

CHarlie
 
> Thanks,
> 
> dmp
> 
> Charlie Poole wrote:
> > Hi Daniel,
> >
> >   
> >>> Generally, if you want it to be non-runnable (yellow) do 
> it at load 
> >>> time and if you want it to fail (red) do it at run time
> >>>       
> >> I asked this several weeks ago and never saw and answer.  
> >> NUnit currently supports the attributes [Ignore] and 
> [Explicit].  The 
> >> only difference I have seen thus far is that [Explicit] 
> allows you to 
> >> run a test if you choose to do so (It goes from Yellow to Red or 
> >> Green), without removing the attribute, and [Ignore] does 
> not.  What 
> >> is the reason for having both?  Is there a reason why [Ignore] 
> >> shouldn't be either depricated or turned into an alias of 
> [Explicit]?  
> >> At the very least, for 3.0?
> >>     
> >
> > First, a correction... Explicit shows as grey, not yellow. It was 
> > yellow in an early version, but that was a bug.
> >
> > Ignore is treated by NUnit as a problem - that's why it shows as 
> > yellow. Explicit is not treated as a problem. Some people, 
> I suspect, 
> > use Explicit to give the effect of an Ignore that never shows up on 
> > the test reports, but I don't think that's a good practice.
> >
> > The idea of Ignore is that you are temporarily stopping the 
> running of 
> > a test for some reason - like it crashes the whole run - 
> but you will 
> > be solving the problem in a short time. Teams I work with 
> get a daily 
> > list of ignored tests from the nightly run and it's supposed to be 
> > short or empty and any igored tests should not stay there long.
> >
> > An Explicit test is one that is not ever intended to be part of the 
> > regular continuous or nightly test runs. Therefore, NUnit silently 
> > passes over them without reporting anything wrong at all.
> >
> > So while some people may use them in similar ways, they are 
> intended 
> > for different purposes and NUnit therefore reports them differently.
> >
> > That said, I think we do need to look at the options for various 
> > RunStates and ResultStates for tests in 3.0.
> >
> > Charlie
> >   
> >> dmp
> >>
> >>
> >>     
> >
> >
> >
> >
> >   
> 



-------------------------------------------------------------------------
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.