nunit

Integration testing using Selenium and NUnit - From UI to DB

Hello! I am having some problems while trying to create integration tests with Selenium and NUnit. I'm trying to use Selenium RC in NUnit test to drive my ASP.NET web app, and would like the tests to actually do all the stuff in DB that the real user would do. Naturally it would be nice if the database could get rolled back after Selen...

NUnit GUI Runner Multiple Configuration Files

Hi I created a test project using a web.config file by renaming it to same name as the project, copying it to the bin folder and setting the Configuration File Name of the NUnit GUI runner to the name of my config file. Now I want to add more assemblies to this project but the problem here is each assembly has it's own web.config file. ...

Has anybody integrated NCover with TFS?

Over the past year my group (some 50 engineers) moved onto Team Foundation Server and are now using it for source control, bug tracking and building. We have tens of thousands of lines of existing NUnit code that we continue to rely on and which we will never convert to MSTest. We have our builds set up such that NUnit posts results wi...

Support for Database testing in NUnit?

I'm aware of the fact that database testing (CRUD) can be considered out of NUnits scope, since it's not quite unit testing, but nevertheless : Is there any standard way in NUnit for database testing? Something in the lines of rolling back transactions made, or any other solution I cannot come up with? ...

How can I pay only once to provide the same expensive data source to multiple unit tests?

G'day! I have 4.6GB of test data in 220,000 files. A bulk test requires finding, matching, and unzipping pairs of the files. I want to run multiple unit tests across each pair. It'll take a dreadfully long time if I can't persuade the test framework to find, match, and unzip the test data only once regardless of the number of unit tests...

NUnit - Is it possible to check in the TearDown whether the test succeeded?

I would like to have my TearDown method check whether the previous test was a success before it applies some logic. Is there an easy way to do this? ...

Pass Parameters to Rails Unit Tests

I was wondering if there is a way to pass arguments to individual tests in rails similar, or similar in idea, to NUnit's TestCase Attribute. Thanx ...

ReSharper Unit Test Runner - TestCase

I like using the ReSharper unit test runner, but it doesn't support the TestCase attribute that was added in NUnit 2.5. Is there any hack to get round this? I can obviously use another test runner, but I like the ReSharper one. ...

Generating Sequence Diagrams using EnterpriseArchitect v7.5?

I have a NUnit test case which connects to a WCF service hosted in IIS6 (on Vista). I would like to use EA to record the stack-trace of this and generate a sequence diagram. Does anyone have any step-by-step instructions in how to get can be done (or even how to get any recording done when using NUnit) using EA? Thanks. ...

Is there anything I can do in NUnit that I can't do in MSTest?

This question has been asked in various forms in a number of different forums, but, IMHO, I haven't been able to find a place where it's really answered clearly, so I'm going to reframe it and ask it again. I work in a basically Microsoft Shop. We use TFS, and all of our developers have MSDN subscriptions including the Team Suite editio...

Is there a tool to merge NUnit result files?

For unclear reasons my Nunit test fixture cannot be executed in a single run, so I'm forced to execute a few tests in separate runs. However this means that the test results are splitted over multiple output files. Is there a tool available which can merge NUnit result XML files into a single XML file? I've tried using the existing Nun...

reusing test suites with multiple implementations?

I'm testing with nUnit. I have a suite of tests that run against my IFoo interface; the Test Fixture Setup determines which IFoo implementation to load and test. I'm trying to figure out how to run the same suite against a list of IFoo implementaions, but don't see any way to test all implementations without manually modifying the Setu...

Yet another "could not load file or assembly ... or one of its dependencies. The system cannot find the file specified"

...

TestDriven.Net nunit.framework error

I am running TestDriven.Net version 2.23, NBehave version 0.4.0.133, and nunit version Unit 2.5.0.9122. I am also running the latest version of Resharper. Here is a snipet of test code: var address = new Address { ActiveYN = true, Address...

How to use NUnit with SnippetCompiler ?

I try to use NUnit with SnippetCompiler http://www.sliver.com/dotnet/SnippetCompiler/ I have added references to nunit.framework.dll in snippetcompiler (Menu Tools, References) and compiled nunit sample http://www.nunit.org/index.php?p=quickStart&r=2.5.2 to bank.dll but when I open bank.dll in NUnit GUI it fails saying it cannot lo...

[.Net] Is it possible to change the way unit tests are invoked?

My guess is that the current semantics of unit testing involve actually calling the method, i.e., if I have a method MyTest() then that's what gets called. My question is this: is it possible to somehow change the pipeline of the way tests are executed (preferably without recompiling the test runner) so that, say, instead of calling the ...

Programmatically adding and removing log appenders in log4net

Hi. I have a component that uses log4net. I want to create unit tests, that validate that certain error conditions result in the correct logging. I was thinking that the best way to do this is to create an ILogAppender implementation, for example a mock. I would then add the log appender to log4net during test setup, inspect what was w...

Unit Testing a Customer's Installation (with NUnit and MSTest)

I've developed a large base of unit tests for my company's application, and dev would like to hand my unit tests over to our support department to help them debug customer installation problems. I wrote my unit tests using mstest, so support would have to install Visual Studio on a customer's machine if they wanted to use my tests out o...

Silverlight Unit Testing

I've searched for this info and see similar questions, but not one that matches very closely to this. If I missed one, I apologize. I was hoping that you'd be able to point me in a direction. I'm working on a Silverlight based project and my team is finally moving toward implementing unit testing. I and another memeber of my team are...

Running WatiN tests with Nunit error?

When I try to run a WatIn test trough the NUnit ide, I get the error message: ConsoleApplication1.Tests.CanBrowseToMicrosoft: System.Threading.ThreadStateException : The CurrentThread needs to have it's ApartmentState set to ApartmentState.STA to be able to automate Internet Explorer. I created an application configuration file called ...