Questions tagged [nunit-console]

nunit-console.exe is the command line version of NUnit, provided so that you can run your unit tests from the command line.

nunit-console.exe is the command line version of NUnit, provided so that you can run your unit tests from the command line. This is the ideal solution when you need to run your unit tests on a build server or run code coverage with NCover. There's both an x64 and x86 version for running unit tests compiled against 32-bit and 64-bit modes.

In NUnit3, the executable was renamed nunit3-console.exe

272 questions
43
votes
4 answers

How do I install NUnit 3 console on Windows and run tests?

I want to run tests from a console like this (being in any directory, the DLL file can be for a different .NET version): $ nunit3-console test.dll I googled a lot, but can't find how to set up this. The official tutorial has nothing useful and is…
one_mile_run
  • 3,264
  • 4
  • 26
  • 29
32
votes
3 answers

Where can I find the meaning of NUnit console exit codes?

I am getting error message from my MSBuild: "nunit-console.exe" exited with code -100. Where can the meaning of the NUnit console exit codes be found?
DarkDeny
  • 1,750
  • 2
  • 21
  • 31
32
votes
4 answers

Pass parameters via the command line to NUnit

Is it somehow possible to pass values to NUnit tests via the command line? My tests use a certain URL. I have different instances of my code at different URLs and would like to specify the URL via the command line. File App.config is not an option,…
Achim
  • 15,415
  • 15
  • 80
  • 144
18
votes
1 answer

How to run nunit with msbuild from VS2010

please tell me how to run nunit with msbuild. I am using TFS for code integration and VS2010 .
Rajesh
  • 2,472
  • 3
  • 25
  • 31
16
votes
2 answers

pass test case parameters using nunit console

I am developing tests using Nunit and data driven testing approach. I have test method with 2 parameters: path to xlsx file and worksheet name. It works perfect in Visual Studio when I pass parameters in TestCase attribute, for example when I want…
kotoj
  • 769
  • 1
  • 6
  • 25
11
votes
1 answer

C# SMO Database do not log creation

I have an integration test that creates a database of type Microsoft.SqlServer.Management.Smo.Database: var defaultConnectionConnectionString = ConfigurationManager.ConnectionStrings["DefaultConnection"].ToString(); var sqlConnection = new…
Scotty H
  • 6,432
  • 6
  • 41
  • 94
11
votes
2 answers

How do I get both test detail and coverage using NUnit and dotCover?

I'm running dotCover with NUnit3 to get coverage reports on our build server. We also need the detail output from NUnit to show the test results. Is there any way to get both the NUnit test detail and the files for dotCover without running NUnit…
Richard Schaefer
  • 525
  • 3
  • 13
  • 45
10
votes
1 answer

How do I get nunit3-console to output my debug to screen (on a Windows box)?

I have used NUnit to run my C# unit tests successfully within Visual Studio 2013, with the NUnit GUI and with NUnit console. For the first two I can get to my debug output (Console.Write(...)). In Visual Studio 2013, it is viewable by clicking the…
code_fodder
  • 15,263
  • 17
  • 90
  • 167
10
votes
4 answers

Use NUnit Console Runner to run all tests under a folder

I am trying to use NUnit Runners 2.6.4 to run all test assemblies in my test folder. My current command looks like this: /nologo /noshadow /framework:net-4.0 /xml:.\test\TestResults.xml .\test\*.Test.dll Unfortunately Nunit just throws a…
hoangbv15
  • 360
  • 2
  • 4
  • 14
10
votes
2 answers

NUnit fail with System.ArgumentException: The net-4.0 framework is not available

Exception: ProcessModel: Default DomainUsage: Single Execution Runtime: net-4.0 Unhandled Exception: System.ArgumentException: The net-4.0 framework is not available Parameter name: framework at NUnit.Util.TestAgency.GetAgent(RuntimeFramework…
Andreas Öhlund
  • 5,263
  • 20
  • 24
10
votes
3 answers

How to run explicit test cases of Nunit

My test suite project contains some explicit test cases, now i want to execute the test cases with the help of Nunit-console.exe. When I execute the test cases, the explicit test cases were excluded from the execution. So, I have tried to execute…
kirana
9
votes
1 answer

Running tests on Mac OS X console using mono/nunit-console/4

I have Max OS X 10.11.1 installed, with Xamarin on it. I wrote simple testing class, just to test running Nunit tests on Mac OS X & Ubuntu, class has literally one method which returns string: using System; namespace testing_project { public…
Jakub Zak
  • 1,212
  • 6
  • 32
  • 53
8
votes
4 answers

How to run NUnit Runner in Atlassian Bamboo with NUnit 3?

I used NUnit Runner in Atlassian Bamboo (latest version) with NUnit 2 but after upgrading to NUnit 3 it is no longer working. It appears something changed with the command line in NUnit 3. Anyone know how to make NUnit 3 work in Atlassian Bamboo? …
Neal
  • 9,487
  • 15
  • 58
  • 101
8
votes
1 answer

NUnit sometimes ends with "unable to locate fixture"

The NUnit-console 2.6.3 sometimes prints out the following error message instead of running tests. Here is excerpt from my Jenkins test build logs: 00:05:02.982 Process 'nunit-console-x86' [PID 3684] has begun profiling. 00:05:03.698 NUnit-Console…
krzysiek_w
  • 81
  • 5
7
votes
7 answers

Database for Importing NUnit results?

I have a large set of NUnit tests; I need to import the results from a given run into a database, then characterize the set of results and present them to the users (email for test failures, web presentation for examining results). I need to be…
Paul Sonier
  • 38,903
  • 3
  • 77
  • 117
1
2 3
18 19