FAKE - F# Make


DotCover

Contains a task which can be used to run DotCover on .NET assemblies.

Nested types and modules

TypeDescription
DotCoverMergeParams
DotCoverParams

The DotCover parameter type for running coverage

DotCoverReportParams
DotCoverReportType

Functions and values

Function or valueDescription
buildDotCoverArgs parameters
Signature: parameters:DotCoverParams -> string
buildDotCoverMergeArgs parameters
Signature: parameters:DotCoverMergeParams -> string
buildDotCoverReportArgs parameters
Signature: parameters:DotCoverReportParams -> string
buildParamsAndExecute (...)
Signature: parameters:'?8412 -> buildArguments:('?8412 -> string) -> toolPath:string -> workingDir:string -> unit
Type parameters: '?8412
DotCover setParams
Signature: setParams:(DotCoverParams -> DotCoverParams) -> unit

Runs the DotCover "cover" command, using a target executable (such as NUnit or MSpec) and generates a snapshot file.

Parameters

  • setParams - Function used to overwrite the DotCover default parameters.
DotCoverDefaults
Signature: DotCoverParams

The DotCover defaeult parameters

DotCoverMerge setParams
Signature: setParams:(DotCoverMergeParams -> DotCoverMergeParams) -> unit

Runs the DotCover "merge" command. This combines dotCover snaphots into a single snapshot, enabling you to merge test coverage from multiple test running frameworks

Parameters

  • setParams - Function used to overwrite the DotCover merge default parameters.

Sample

DotCoverMerge (fun p -> { p with 
                    Source = [artifactsDir @@ "NUnitDotCover.snapshot"
                              artifactsDir @@ "MSpecDotCover.snapshot"]
                    Output = artifactsDir @@ "DotCover.snapshot" }) 
DotCoverMergeDefaults
Signature: DotCoverMergeParams
DotCoverMSpec (...)
Signature: setDotCoverParams:(DotCoverParams -> DotCoverParams) -> setMSpecParams:(MSpecParams -> MSpecParams) -> assemblies:seq<string> -> unit

Runs the DotCover "cover" command against the MSpec test runner.

Parameters

  • setDotCoverParams - Function used to overwrite the DotCover report default parameters.
  • setMSpecParams - Function used to overwrite the MSpec default parameters.

Sample

!! (buildDir @@ buildMode @@ "/*.Unit.Tests.dll") 
    |> DotCoverMSpec 
        (fun dotCoverOptions -> { dotCoverOptions with 
                Output = artifactsDir @@ "MSpecDotCover.snapshot" }) 
        (fun mSpecOptions -> { mSpecOptions with
                Silent = true })
DotCoverNUnit (...)
Signature: setDotCoverParams:(DotCoverParams -> DotCoverParams) -> setNUnitParams:(NUnitParams -> NUnitParams) -> assemblies:seq<string> -> unit

Runs the DotCover "cover" command against the NUnit test runner.

Parameters

  • setDotCoverParams - Function used to overwrite the DotCover report default parameters.
  • setNUnitParams - Function used to overwrite the NUnit default parameters.

Sample

!! (buildDir @@ buildMode @@ "/*.Unit.Tests.dll") 
    |> DotCoverNUnit 
        (fun dotCoverOptions -> { dotCoverOptions with 
                Output = artifactsDir @@ "NUnitDotCover.snapshot" }) 
        (fun nUnitOptions -> { nUnitOptions with
                DisableShadowCopy = true })
DotCoverReport setParams
Signature: setParams:(DotCoverReportParams -> DotCoverReportParams) -> unit

Runs the DotCover "report" command. This generates a report from a DotCover snapshot

Parameters

  • setParams - Function used to overwrite the DotCover report default parameters.

Sample

DotCoverReport (fun p -> { p with 
                    Source = artifactsDir @@ "DotCover.snapshot"
                    Output = artifactsDir @@ "DotCover.xml"
                    ReportType = DotCoverReportType.Xml })
DotCoverReportDefaults
Signature: DotCoverReportParams
getWorkingDir workingDir
Signature: workingDir:string -> string
Fork me on GitHub