Top "Nunit" questions

NUnit is an open source unit testing framework for .NET and Silverlight written in C#. It serves the same purpose as JUnit or TestNG does in the Java world, and is one of many in the xUnit family.

One-time initialization for NUnit

Where should I place code that should only run once (and not once per class)? An example for this would …

c# .net nunit
Is it possible to parameterize a nunit test

I would like to write a callable function that accepts two objects, and compares 30+ properties of those objects with asserts. …

c# nunit
The current SynchronizationContext may not be used as a TaskScheduler

I am using Tasks to run long running server calls in my ViewModel and the results are marshalled back on …

c# multithreading nunit task-parallel-library resharper-6.0
Using Verify to confirm expected parameter values in Moq mock class

I'm trying to verify that a method within a mock is called with an expected object parameter. I'm using Moq, …

nunit moq autofixture
How to assert that two list contains elements with the same public properties in NUnit?

I want to assert that the elements of two list contains values that I expected, something like: var foundCollection = fooManager.…

c# .net unit-testing nunit assertion
How do I enforce exception message with ExpectedException attribute

I thought these two tests should behave identically, in fact I have written the test in my project using MS …

c# unit-testing nunit mstest expected-exception
How can I load this file into an NUnit Test?

I have the following IntegrationTest project structure ... If i wish to use that test data 126.txt in an NUnit Test, …

c# .net testing tdd nunit
How can I add log messages to an NUnit test that will appear in a nant build execution?

With NUnit, if you add Debug.Print statements in your tests they appear in the test output. (At least they …

logging nunit nant
NUnit isn't running Visual Studio 2010 code

I'm trying to load a Visual Studio 2010 beta dll into the NUnit GUI. I get a popup error. This assembly …

visual-studio-2010 visual-studio debugging nunit
SpecFlow and complex objects

I'm evaluating SpecFlow and I'm a bit stuck. All samples I have found are basically with simple objects. Project I'm …

c# nunit bdd specflow