Why to use NUNIT?

Topics: CAB & Smart Client Software Factory
May 12, 2005 at 10:18 AM
originally posted by: YosiTaguri

Hi,
I was wondering, you are doing it all in Whidbey, why did you choose NUNIT over the ineternal unit testing facilities in Whidbey?
May 12, 2005 at 10:23 AM
originally posted by: TimLandgrave

I'm trying to get the thing up and working and my first compile gave 700 errors - most related to NUnit. If I install NUnit 2.0 will everything work? More importantly, this is going on a VSTS Beta build. Will it break any VSTS functionality?
May 12, 2005 at 9:13 PM
originally posted by: eugeniop

We are using NUnit because when the project started, Visual Studio Team System was not stable enough for us to use the testing facilities we needed. So we elected to use NUnit rather than go without unit tests at all. Now that VS Team System is approaching maturity, we are looking at what it would take to move to the new system.

BTW, the version of Nunit you need to install is 2.1.4 (see the readme.doc in the zip file)
May 13, 2005 at 2:22 AM
originally posted by: dotnetboy2005

In a lot of our newer unit tests we are doing the following so that it is easy to use with VSTS or NUnit:

#if VSNET
using Microsoft.VisualStudio.QualityTools.UnitTesting.Framework;
#else
using TestMethod = NUnit.Framework.TestAttribute;
using TestClass = NUnit.Framework.TestFixtureAttribute;
using TestInitialize = NUnit.Framework.SetUpAttribute;
using TestCleanup = NUnit.Framework.TearDownAttribute;
using NUnit.Framework;
#endif

We then use attributes like VSTS:
TestClass
TestInitialize
TestCleanup
TestMethod
May 17, 2005 at 10:14 PM
originally posted by: FPaulBallard

In any case it would be nice if you included the NUnit DLLs that you used for linking in addition to the NMock dll so that we don't have to install NUnit or NMock to compile the code.
May 18, 2005 at 6:21 AM
originally posted by: PProvost

I hear you. Unfortunately, we can't really ship those DLLs in our package.

As for NMock, it has been completely removed from the code and will not be in the next drop.

Sorry for the confusion.
Jul 3, 2005 at 12:46 PM
originally posted by: Cubes

Why can't you ship those dlls? That doesn't make any sense to me, there isn't anything in the license (http://www.nunit.org/license.html) that says you cannot distribute the dlls or source if needed.

Could it be politics at MS?
Jul 5, 2005 at 9:44 PM
originally posted by: PProvost

Actually, it is quite simple:

1. We don't ship compiled code. That's just the way we work.

2. Nobody ships NUnit DLLs with their code. They announce which version of NUnit they support and expect you to have that. If everyone included the NUnit asemblies then we would just end up with a massive pile of redundant bits out there taking up space.

There is no great conspiracy against NUnit here. (You may not know, but until a few months ago the Dev Lead here was Jim Newkirk--the guy who basically wrote NUnit 2.0.)