Home | Forums

Options Tool Window

Clover Options Tool Window

The Clover Options tool window is activated by selecting the Options entry from the Clover menu.

The Clover.NET plugin only loads when required, so you may notice that initially all menu items except for the Options item are disabled. This is normal. Once the Options item is selected, Visual Studio will load the Clover.NET plugin and the remaining items will become enabled as appropriate. The layout of the Clover.NET options tool window is shown below

Clover Options Window

The options tool window consists of a Clover.NET toolbar with buttons for most common Clover.NET functions and a properties window to control the operation of Clover.NET. The toolbar also appears on the Coverage View tool window and corresponds with the items on the Clover menu. The following table details the function of each of the Clover options properties.

Coverage Display Enabled This option controls the display of coverage information in the Visual Studio editor. It corresponds to the Display button on the toolbar. When this property is set to True and there is coverage information loaded, Clover.NET will display the current coverage information within the Visual Studio Editor. Refer to the Coverage Display section for more details.
Additional Files Clover.NET determines the files it must instrument and copy by using the project information maintained by Visual Studio. If a file is required which is not included in the project hierarchy, you must add it explicitly using this option. You can type the file names in directly or use the associated dialog to select and add files or folders interactively. All files are added relative to the Solution file. Clover.NET will not handle key file references for assembly signing automatically. The key files do not need to be added explicitly.
Build Config This is the build configuration that Clover.NET will use when building the Clovered projects. This defaults to the DEBUG configuration. This setting will affect which preprocessor definitions are used when instrumenting the source.
Build Location This option controls where Clover.NET will create the Clovered versions of the projects within your solution. By default this is set to the directory CloverBuild relative to the Solution file. When Clover.NET has finished Clovering and building your projects, you will find the output assemblies here. These are the assemblies you need to use in testing to generate coverage recordings.
Clover Database This determines the location of Clover.NET's coverage database. The default is to create the database at CloverBuild\clover.cdb relative to the solution. This approach keeps all Clover.NET related files in one area. You may, however change this to any location you like. In particular you can select an existing database if you wish to aggregate coverage recording across a number of solutions.
Excluded Solution Projects In many solutions you may not want to Clover all projects. For example, you may have your unit tests as a separate project within the solution and not want coverage information on the tests themselves. The option provides a dialog where you can select which projects to exclude from Clovering. Excluded projects are still copied to the CloverBuild area but are not instrumented. The excluded projects are also built to satisfy inter-project dependencies, etc. If you are testing and the test project is excluded from Clovering, you should use the version built in the CloverBuild area as it will run with its Clovered dependencies.
Flush Interval and Flushing These two properties control the insertion of flushing code into the instrumented code generated by the plugin. Normally coverage information is written out when the AppDomain is unloaded. This usually occurs when the application closes. Flushing is used to write out coverage information without needing to have the application close.
Instrument Assignments Instrument boolean expressions which contain assignments. In some conditions the instrumentation of boolean expressions can affect the compiler's ability to determine whether an uninitialized variable has been used. With this set to false, Clover.NET will not attempt to instrument such expressions.