Continuous Integration / Build with NUnit 2.5.x and .Net 4.0

Ok, so here is my current installation and my problem at the moment. I have a growing set of projects in a Visual Studio solution. The solution contains about 15 projects (give or take several) and a rapidly growing code base. I understand that before I got to this, I should have had a continuous build system, but I suppose it's never too late. Therefore, after doing a little research, I believe that my ideal setup would be:

  • NUnit 2.5.x (we are already tied to this ... so necessary)
  • Integration with CruiseControl.Net (open for other options, but only for free with Git support)
  • Integration with a code coverage tool ( NCover , DotCover ) will be pleasant
  • Integration to run shell commands (for JSLint and compression tools, etc.)

What I am missing is a tool for starting automatic assembly. I looked at NAnt , but it supported the launch of MSBuild (to create a project), it seemed to be rather outdated (we use VS2010 ), and using solution files in our build process would be a great splash time. I also looked at MSBuild (for obvious reasons), but the process I found to run NUnit tests only supports the 2.4.x extension project ( MSBuild ).

I am curious how everyone else organized their continuous build systems. NUnit , if quite popular, so I should not be the only one who is asking this.

+4
source share
3 answers

My first question is: how can you create projects?

Teamcity Professional is free for 20 build configurations per server and will make your sooooo style much easier, it has a built-in set of layouts and it is really easy to configure, run tests, etc., and this is by far the most baked CI server.

Jenkins is the next runner-up, this is Hudson's plug and very flexible with plugins
do anything, making it a little more flexible than Teamcity, but it’s not so easy to set up, code coverage is a pain that needs to be set up, and has some annoying quirks, but completely free.

if you don’t have a really strong reason to use CruiseControl.Net, do not worry, because this time was very powerful, but now it is sadly outdated and painful to use.

Regarding build customization, both Teamcity and Jenkins support MSBuild, NAnt, Rake, etc., they also support several build steps, for example, in the msbuild or Nant file. What I did in the past is just to use the .sln file to create the assembly with one build step, use the build task for unit tests, then use the built-in task to cover the code, and then use another build task to click the files.

I used TeamCity, Jenkins, TFS, and I tried using CruiseControl.Net but found it painfully awkward. In addition, Teamcity is the best, and Jenkins is the second, I would not want to use TFS, even if I had it.

If you have any questions, feel free to contact me.

+4
source

You can use NAnt to create Visual Studio 2010 solutions. I do this all the time. I provided a sample NAnt script in my answer here: <msbuild> task or msbuild.exe with NAnt?

+2
source

If you just need to compile and run the tests, you can’t go wrong with TeamCity , it perfectly supports NUnit / VS and many built-in reports.

If you need to run a more complex build script, I suggest you use FinalBuilder to create the build script and TeamCity Team Runner to run this script. By importing the test result into TeamCity, you can still receive reports, and there is an easy way to display the assembly status from FinalBuilder to TeamCity:

0
source

All Articles