V4 Documentation

Impact Detection Mode

NCrunch Global Configuration setting Default Value: CompareIL
ID/Tag in config file: ImpactDetectionMode


This setting controls the behaviour of NCrunch's test impact detection system.

Impact Detection Modes


Under this mode, NCrunch will compare built assemblies against their previous versions at IL-level to perform a detailed analysis of which tests are impacted by changes made to the solution. Any tests that physically cover methods or access files that are affected by changes will be automatically marked as impacted by NCrunch.

This impact detection method is not 100% comprehensive. For example, it does not currently consider metadata dependencies handled through reflection. However, it does handle a wide range of edge cases such as polymorphism and use of resource files inside NCrunch workspaces (provided the track file dependencies project-level configuration setting is enabled). The goal of this impact detection mode is to be accurate enough that unimpacted tests can be safely excluded from automatic execution in most situations.


Under this mode, NCrunch will consider any tests covering any line within a changed source file to be impacted. No consideration is made for the physical structure of an assembly or any code elements.

This mode is much more rudimentary than CompareIL and is much less accurate. Its major advantage is that with this mode enabled, NCrunch does not need to perform expensive IL comparisons between assemblies. Thus with this mode enabled, the engine may perform marginally better.

Under WatchText, NCrunch is able to mark tests as impacted immediately on source code being changed. There is no need to wait for the engine to build the underlying project.

If the track file dependencies setting is enabled for the project, NCrunch can also mark tests as impacted if they use an included resource file under WatchText.

Prior to version 3, WatchText was the only impact detection mode available in NCrunch.

Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download