Build/Test Issues

Possible issue with F#

Started by gregm on 5,874 views

I'm very new to F# and I'm doing a like project to try and learn some more. I thought it would be cool to use testing as part of it, to see how that works. I'm running into an issue where an item from the SUT is null, when it shouldn't be.

I've already asked the question on StackOverflow, so I'll reference there: http://stackoverflow.com/q/24710683/99559.

Is there any information on the correct way to setup tests for F# projects using NCrunch? Suggested testing frameworks? And why is this issue happening?
Hi, thanks for posting.

I'm not aware of anything in NCrunch that would specifically cause this problem. It's possible that NCrunch is surfacing the issue indirectly, or that you've discovered something unusual between the multiple toolsets in use here (NCrunch/MSBuild/FSharp/NUnit).

I think it may be worth trying to place your NCrunch in compatibility mode to see if this makes any difference.

Do you experience this problem when attempting to run your tests directly using NUnit? (i.e. the NUnit GUI or console runner). Note that TestDriven.NET isn't always the same as these.

If you can submit a buildable/runnable code sample that I can play with, I should be able to help find the problem very quickly. You can submit code via the contact form.


Thanks!

Remco
Thanks for answering so quickly Remco!

I submitted a zipped solution to the contact form. It should be pretty self explanatory.

Please note that based on the StackOverflow responses, I did try to run the code in FSI and I got the same results there...which leads me to think it might not be NCrunch specific. It is more likely a PEBKEC. =:-o

I appreciate you taking a look!

Greg
Thanks for the sample solution.

Running this test produces the exact same results between NCrunch and vanilla NUnit, so I'm afraid there's nothing I can do to help here. It will be interesting to see the response to your stackoverflow question.

Post a reply

Log in to reply.