views:

208

answers:

5

We have a lot of unit tests but they aren't run every night. I have setup some batch files that compile all the code from the SVN repository and I would like to run NUnit. This is not a big problem because I can call it from the batch file after the compilation BUT the output is stored in the network drive and I need to open it every morning to check if errors happen. This is where the problem is.

Do you have a better way to do the same thing that will take the code from the repository, execute test and tell me in a "more fast convenient way" if errors appears?

Update I have installed Team City 4.0 nd it work like a charm. Maybe Cruise Control .Net could have been done the same, but Team City website/documentation/features looked better. Thank all.

+10  A: 

Sounds like you need a build server. See Cruise Control .Net

Andrew Cox
Definitely. There are currently only two programmers working on .NET stuff right now, but I've setup a build server for this specific purpose. Whenever either of us checks in new code to Subversion, the build executes and gets tested.
Nick DeVore
Agreement from me - that's exactly what we do.
David A Gibson
+1: we are using CC.NET with Sharepoint integration, works well.
boj
A: 

Check out What is the best way to send an email from a batch file?

All you need to do is extend this to type the log file into the tempory email file.

type NUnitLogFile.txt>>tmp.txt
Martin Brown
Not a good solution, the output is over 10 megs and I do not want to receive it, if doesn't have any error.
Daok
You don't have to attach the output and you can use IF ERRORLEVEL to detect whether nunit failed.
Martin Brown
I agree this is probably not the best solution, but it would be the least work seeing that you alreay have a batch file written.
Martin Brown
+1  A: 

What about Team City? I am still searching and I have see their product that looks to be able to do what I am searching for.

Why CruseControl.Net get so much vote when I see this Matrix, Team City looks to be better...

Daok
A lot of it is probably familiarity - I've built multiple CI systems on CruiseControl.Net and NAnt, but never heard of TeamCity until today. Also, the matrix doesn't describe the features in enough detail, nor are some represented correctly (CC.NET notifications, for example)
GalacticCowboy
I am very interested bu Team City since the install can be done very fast and no need to configure a lot of file like I read about CC.NET. I'll keep reading and my find something wrong with Team City, I'll post it here.
Daok
+2  A: 

We have recently started using TeamCity with our projects, and so far it seems great. We are using it with Subversion and NUnit, aswell as running an external program which makes the final install file of the application. The projects and build configurations are really easy to set up.

atsjoo
A: 

We have a nightly test driver based on FIT with a special fixture for running NUnit on DLLs. The testing fixture captures the output and looks for the final summary line that says how many tests passed and failed.

A corollary question we are facing is how to conveniently display the full NUnit output in HTML without mucking about with gross amounts of XSLT... Any utilities out there that convert console-NUnit output to HTML?

Jeff Kotula