Discussion:
Need Feedback: RequiredAddinAttribute
Charlie Poole
2008-07-16 19:27:44 UTC
Permalink
Hi All,

The 2.5 Alpha 3 release of NUnit includes the RequiredAddinAttribute,
used to indicate that a test expects a particular addin to be installed.
This is intended to give a failure if the addin is not present.

As explained at http://nunit.org/?p=requiredAddin&r=2.5 the attribute
will not always be seen by NUnit when it is placed on a method or
a class. I'm thinking of disallowing it on methods and classes in
the next release for that reason. What do you think?

Charlie

PS: This note has been sent separately to multiple mailing lists so
you may get it more than once. This seems preferable to cross-posting.




-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
Kelly Anderson
2008-07-18 17:17:01 UTC
Permalink
I don't have strong opinions on this topic, but I do have a use case
to consider in the conversation.

Suppose that you distribute your tests with your program to be run
after install. If your tests require that a particular Addin be
installed, it would be nice to have an explicit message that told the
customer why the tests didn't pass (Addin X Required by NUnit) instead
of just having hundreds of tests fail for reasons that might not be
immediately clear. Possibly worse yet, all the tests pass and the user
thinks all is well because NUnit doesn't recognize the test classes as
even being tests without the Addin present.

-Kelly

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
Charlie Poole
2008-07-18 23:16:53 UTC
Permalink
Hi Kelly,

Good point! In such a situation, I'd definitely want to
use the attribute.

Charlie
-----Original Message-----
Behalf Of Kelly Anderson
Sent: Friday, July 18, 2008 10:17 AM
Subject: Re: [nunit-developer] [Nunit-users] Need
Feedback:RequiredAddinAttribute
I don't have strong opinions on this topic, but I do have a
use case to consider in the conversation.
Suppose that you distribute your tests with your program to
be run after install. If your tests require that a particular
Addin be installed, it would be nice to have an explicit
message that told the customer why the tests didn't pass
(Addin X Required by NUnit) instead of just having hundreds
of tests fail for reasons that might not be immediately
clear. Possibly worse yet, all the tests pass and the user
thinks all is well because NUnit doesn't recognize the test
classes as even being tests without the Addin present.
-Kelly
--------------------------------------------------------------
-----------
This SF.Net email is sponsored by the Moblin Your Move
Developer's challenge Build the coolest Linux based
applications with Moblin SDK & win great prizes Grand prize
is a trip for two to an Open Source event anywhere in the
world http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
nunit-developer mailing list
https://lists.sourceforge.net/lists/listinfo/nunit-developer
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
Charlie Poole
2008-07-18 23:22:07 UTC
Permalink
Thanks for your feedback, which came on several lists as well as direct to
me.

I have now limited the attribute to use at the assembly level, since that
works
exactly as one might expect.

Charlie

Loading...