The following chapter includes instructions on how to configure and run IncrediBuild for Unit Tests to run in Assembly-level mode or Test-level mode with the NUnit framework. The setting that specifies the Assembly or Test level modes for NUnit is specified within the IBTestConsole command, as described below.
Supported Frameworks:
IBTestConsole supports the following frameworks:
- NUnit 2
- NUnit 3
- Google Test (Gtest)
IBtestConsole will automatically detect the executed framework. However, if you want to force it to run a specific framework, you can use the /test=NUnit3 or /test=NUnit2 CLI command line options.
Running the IBTestConsole
To configure and run the IBTestConsole, you should first run the IBTestConosle.exe file, located in the IncrediBuild installation folder. This is a console application that initializes IncrediBuild for Unit Tests in various modes of operation, according to its various parameters.
IBTestConsole Commands Usage
The IBTestConsole commands follow the following syntax:
IBTestConsole [command] [options]
- Command - stands for the original command of your Unit tests framework. The command may include flags (described below).
- Options – one of the options described in the section below.
Supported Framework Command Flags
The following framework command flags are supported by IncrediBuild for Unit Tests. Each framework version includes different flags as described below. To learn more about each flag, please refer to the following resources:
Nunit 3 CLI reference: https://github.com/nunit/docs/wiki/Console-Command-Line
Nunit2 CLI reference: https://nunit.org/docs/2.6.2/consoleCommandLine.html
NUnit 2 Supported Flags
/run
/runlist
/include
/exclude
/result, /xml
/noresult, /noxml
/framework
/timeout
NUnit 3 Command Flags
@FILE
--testlist=FILE
--where=EXPRESSION
--config=NAME
--framework=FRAMEWORK
--timeout=MILLISECONDS
--seed=SEED
--skipnontestassemblies
--result=SPEC
--noresult
--shadowcopy
--noheader, --noh
--params | p=PARAMETER
--dispose-runners
GTest Command Flags
--gtest_output
--gtest_filter
IBTestConsole Options
The following options can be added at the end of the IBTestConsole command.
Option | Mandatory | Description | Notes |
---|---|---|---|
/OpenMonitor | Opens the Execution Monitor window, which shows the execution progress. | ||
/TargetDir | Specifies the working directory on which the test framework operated. | This command should be used in case the IBTestConsole was not initiated from the same directory as the test assemblies. | |
/test={framework} | Forces IBTestConsole to handle the executed command as a specific framework. | By default, IBTestConsole will try to detect the target framework executed. Use this option to force IBTestConsole to handle the executed command as a specific framework. Supported frameworks:
| |
/TestLevel=N | Specifies the following
| The number of cores to be used may determine the efficiency of the parallelization. In general, you should set the /testlevel=N command option so that N should be around x2.5 of the number of cores that you have on your local machine. To learn more about test level optimization, see Advanced Test Level Optimization.
| |
/Help | Prints the help on the screen | ||
/LogFile | Specifies the log file name | ||
/LogLevel | Sets logging level. Default: Error level |
Return Codes
IBTestConsole return the following return codes:
Code | Description |
---|---|
0 | Successfully exited. This means that no internal error occurred during any of the following stages:
|
1 | Internal error during execution for any of stages described above |
-1 | Unexpected internal error. in real shouldn't ever occur |
Visual Studio Solution:
Running a Build from Visual Studio IDE
Running Visual Studio Commands as IncrediBuild Commands
Customizing IncrediBuild Build Options in Visual Studio IDE
Using IncrediBuild and Visual Studio - Integration Modes
Visual Studio Reference
IncrediBuild Solutions:
Visual Studio Solution
Make and Other Build Tools Solution
DevTools Solution
IncrediBuild for Qt Creator
IncrediBuild For Game Development
IncrediBuild for Unit Tests
Working with Build Groups
Running Gitlab Builds with Incredibuild
User Manual:
List of Open Sources
Getting Started
Set Up and Installation
IncrediBuild Solutions
The Coordinator
IncrediBuild Agents
IncrediBuild Cloud
Working from Home
Troubleshooting Issues
IncrediBuild Additional Resources
Release Notes