views:

292

answers:

2

I'm starting a new .Net project, and I would like to know your recommendation for tools to use.

In general, I would like to have the following:

  • Somebody should be able to check out the project and build it with nothing more than mono or .Net installed
  • It should build on as many platforms as possible (or at least Windows and Linux)
  • Somebody should be able to build it automatically (using nant, for example) or from their IDE
  • The automated build should run at least the following:
    • The code should all be compiled (obviously)
    • The unit tests should all be run and any failures reported
  • The following would also be nice, but optional:
    • Provide test coverage data (in an easily readable report, if possible)
    • Build API documentation
    • Provide code metrics analysis (again, with a report if possible)
    • Check for common coding errors and stylistic problems (similar to what FxCop or checkstyle do. Again, with a report, if possible)

In past projects, I've always tended to use the following:

  • Automated build: nant
  • Unit testing: nunit
  • Test mocking: Moq (This is an awesome library)
  • API documentation: Sandcastle (Don't know if this works on anything but Windows)
  • Metrics: sourcemonitor (I don't think this works on anything but Windows)
  • Test coverage: ncover (This is the very old, open source version. Does it work on anything but Windows?)
  • Code checking: fxcop (Does this work on anything but Windows?)

The problems I'm facing with it are:

  • I have to bundle all of this software with the code, giving me nearly 100MB in tools alone. It's either that or require the user to install and configure all of these before they can build the project, which is undesirable. How do you get around this?
  • Many of the tools are difficult to integrate with nant, such as ncover and source monitor
  • Many tools don't work on 64-bit versions of Windows without modification (I'm looking at you, nCover)
  • Some tools run on Windows only
  • Some of the tools are extremely old
  • I can't get very nice looking reports (if any at all) out of many of the tools, and certainly can't get them to look consistent with each other
  • I have to manually alter some of the Visual Studio generated project files to add special configurations (otherwise the automated and integrated builds step on each other)

Unfortunately, the choice of free tools is something that Java definitely wins over .Net. There are an abundance of test coverage tools, code analysis tools, reporting tools, API documentation tools, testing tools, build tools etc. available for Java, but I'm having a hard time finding any for .Net.

So, are there any better and still free alternatives to some of these tools that will work across all platforms that support mono?

What are your recommendations?

+1  A: 

I don't mean to be rude, but this question looks more like a Java vs .Net rant than a valid question, since you already seem to know what the tools are. Yes, there are a lot more open source projects and people working on Java than on .Net (the reasons for this are beyond the scope of this question). That's just how it is right now.

The only way to change this is to do actual open source work. Get involved. If you want some open source tool to work on Mono, first try suggesting it to the project authors. Chances are they never tried their code on Mono or making it work on Mono is a low-priority issue to them. If you can get them to do it, fine. Otherwise, you could either get the code and do it yourself, or hire one of the project members to do it for you.

The key point here is: you need to take action.

I'll try to answer now some of the more specific questions you raise:

Mauricio Scheffer
I mentioned Java once in a tiny paragraph at the bottom of which is, admittedly, quite a huge question. Thus I think calling the whole thing nothing more than a 'Java vs .Net' is entirely unjustified and unfair. In fact, I would go so far as to say that you're wrong.I've already discovered Gendarme and finding it to be a decent replacement. The most I can see for NDepend is a trial version that, while free to use for open source and non-commercial projects, timebombs periodically, requiring a new version or something. Hardly ideal when distributing it with a project.
IRBMe
Bottom line: .Net is not Java. If you try to pretend it is, you'll just end up dissapointed and frustrated. Instead, try to be more pragmatic and deal with reality as it is right now.
Mauricio Scheffer
Nobody said it was and nobody is pretending anything and I can assure you I am very much living in reality. Now you're just attacking strawmen and that IS rude. If truth be told, I'm more frustrated with Java in comparison to .Net.
IRBMe
Like I said, I never meant to be rude. I apologize if you felt I was rude. What I'm trying to say here is that you'll *never* find as many tools (in particular, free) in .Net as there are in Java.
Mauricio Scheffer
A: 

I cant do a long post but have you check out TeamCity. It is a CI environment and pulls together most of the tools you mention and is built on top of java however works well across .net projects. It will not solve all the issues you mention however!

redsquare
This is pretty good actually. I downloaded it and have been having a play around with it and am impressed.
IRBMe