Andrew Stopford's Weblog

poobah

Sponsors

News

Articles

Family

Old Blogs

Make your own MbUnit port for NUnitASP

I have had a few folks ask me about providing the source for the MbUnit port of NUnitASP, as doing this would require forking the NUnitASP code base it was decided that the code would not be added to the NUnitASP project. The good news is, Jim has made a lot of changes that means for the next release you a port can be created and added to the code base with out a fork risk, or you can port a later verson to suit your needs.
  • To do this first download a NUnitASP release, don't obtain the source from CVS unless you get a later branch (due to the changes mentioned previously) its just as easy to get the source from the download section however
  • When you have the source remove the NUnit dll referances and add the MbUnit dll referances (MbUnit Core and MbUnit Framework dlls), make sure you also remove the NUnit referances in the code and referance MbUnit.Core.Framework and MbUnit.Framework.
  • Your going to now get a lot of errrors, as such change the Assertion.Assert calls to Assert.*, by * I mean you will need to match as carefully as you can, by and large use AreEqual and IsFalse/IsTrue but use what ever works best.
With that done you should be able to recompile and run your tests using MbUnit with out a problem. Any questions let me know.

Comments

TrackBack said:

# February 25, 2005 3:38 AM

TrackBack said:

# February 25, 2005 3:39 AM

TrackBack said:

# February 26, 2005 4:17 AM

Carlton Nettleton said:

I am not sure if I follow you here - are your changes going to be incorporated into NUnitASP? Or maybe my question is: can you use NUnitAsp with MbUnit?

# March 1, 2005 7:07 PM

Andrew Stopford said:

The version that sits in CVS is easier to adapt to frameworks other than NUnit. However the changes noted are for versions earlier to this. With that version these changes would have ment branching NUnitASP and so they were not adopted into the code base. However you can easily make the changes your self, the post notes on how you can do this.
# March 3, 2005 7:38 AM

Carlton Nettleton said:

OK. I understand now - you wanted to change the NUnitASP source so it was more generic to other frameworks, but that would have caused a branch. It was decided not to do that.

As a result, you checked out your own version of NUnitASP, did all the "find and replaces" on your own copy, compiled it and are using a "custom" version of NUnitASP that uses MbUnit.
# March 4, 2005 12:31 PM