Jan 01 2007

Getting Fit With .Net: version 0.1 is out! Grab it while it’s hot.

Published by gojko at 2:23 pm under fitnesse

I spent the last month experimenting with FitNesse server for automated testing, especially the .Net integration – with great results. Even the complex tests were quite easy to write, glue-code to bind our libraries to FitNesse is very thin, and I quickly built the framework that held the project code together during major refactoring. There was, however, one missing ingredient in the mix.

The online user guide deals only with the Java integration, and .Net implementation has a lot of subtle differences. Details of those specifics are scattered throughout the Internet, so I spent quite some time collecting partial information from blogs, but on the end, all the roads lead to the debugger. Fitnesse.Net is, fortunatelly, opensource, so I got the source code from Sourceforge and found what is really going on.

As I could not find a complete, consolidated guide that explains how to start testing .Net code with Fitnesse, I decided to write one myself and share it, so that others do not have to learn it from the debugger. Here is the first version – download it from www.gojko.net/fitnesse. This document covers:

  • Setting up a FitNesse server for testing .Net code
  • Writing basic tests, performing common tasks
  • Saving time and effort with specialised test types
  • Tips and tricks for writing better tests and making test pages easier to read
  • Managing content with FitNesse
  • Organising tests into test suites
  • Most important differences between .Net and Java versions

Get notified when I post something new - subscribe via RSS or Twitter!

6 responses so far

6 Responses to “Getting Fit With .Net: version 0.1 is out! Grab it while it’s hot.”

  1. Paulon 04 Jan 2007 at 1:13 am

    Please ignore the last comment. I finally got it to work with your example. Thanks again for the guide. This will make deploying Fitnesse to our .Net team a much more enjoyable proposition.

  2. jenswinter.comon 07 Jan 2007 at 1:49 pm

    FitNesse testing with .NET…

  3. Bert Vanhuyseon 10 May 2007 at 8:51 am

    Hello,

    I’m working with you’re doc and got an error on the first example. Here’s the error:

    ErrorLogs.
    HelloWorld
    Date: 9:43:53 AM (CEST) on donderdag, mei 10, 2007
    Command: java -cp D:\FitNet\FitNet\bin\Debug\netfit.dll d:\fitnesse\dotnet2\FitServer.exe localhost 8888 2
    Exit code: -1
    Time elapsed: -1.178783033762E9 seconds

    ——————————————————————————–
    Standard Error:

    java.lang.NoClassDefFoundError: d:\fitnesse\dotnet2\FitServer/exe
    Exception in thread “main”
    ——————————————————————————–
    Internal Exception:

    java.lang.Exception: FitClient: external process terminated before a connection could be established.
    fitnesse.components.CommandRunningFitClient$EarlyTerminationRunnable.run(Unknown Source)
    java.lang.Thread.run(Unknown Source)

    and in the command prompt I get the following error:
    java.text.ParseException: Unparseable date: “Wed, 19 Jul 2006 17:30:28 GMT”
    at java.text.DateFormat.parse(Unknown Source)
    at fitnesse.responders.files.FileResponder.isNotModified(Unknown Source)
    at fitnesse.responders.files.FileResponder.makeResponse(Unknown Source)
    at fitnesse.FitNesseExpediter.createGoodResponse(Unknown Source)
    at fitnesse.FitNesseExpediter.makeResponse(Unknown Source)
    at fitnesse.FitNesseExpediter.start(Unknown Source)
    at fitnesse.FitNesseServer.serve(Unknown Source)
    at fitnesse.FitNesseServer.serve(Unknown Source)
    at fitnesse.socketservice.SocketService$ServerRunner.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    Do you know how i can solve it

  4. gojkoon 10 May 2007 at 12:25 pm

    Bert,
    you are using a java test runner, not a .net one. See the section on how to set up the .Net test runner (three !define commands)

  5. Navinon 09 Oct 2007 at 5:04 am

    I am trying to implement fitnesse with dotnet application. but i could not find any run.bat file for running fit server. pls guide me how i can run fit server.
    Thank you

  6. gojkoon 09 Oct 2007 at 9:42 am

    Hi,

    which version of fitnesse have you downloaded (and from where)? run.bat is in the main fitnesse folder of the distribution (get it from
    http://www.fitnesse.org/fitnesse20070619.zip?responder=releaseDownload&release=20070619)

    you will have to download .net runner separately from

    http://sourceforge.net/project/showfiles.php?group_id=167811&package_id=219790&release_id=516420

    gojko

Trackback URI | Comments RSS

Leave a Reply