altcover

namespace AltCover

namespace AltCover

module AltCover

  [<RequireQualifiedAccess>]
  module AltCover = begin

This represents the command line options and its validation

type ValidatedCommandLine

    [<NoComparison>]
    type ValidatedCommandLine =
      {
        Command: string list
        Errors: seq<string> }
      with
        override ToString : unit -> string
      end

Holds the composed command line in Command, and any validation errors in Errors.

The ToString() override formats the outcome for pretty-printing

type CollectOptions

The members correspond to the like-named command line options for AltCover Runner, except

    [<NoComparison>]
    type CollectOptions =
      | Primitive of Primitive.CollectOptions
      | TypeSafe of TypeSafe.CollectOptions
      | Abstract of Abstract.ICollectOptions
      with
        interface Abstract.ICollectOptions
        member RecorderDirectory : System.String

        member WorkingDirectory : System.String
        member Executable : System.String
        member LcovReport : System.String
        member Threshold : System.String
        member Cobertura : System.String
        member OutputFile : System.String
        member CommandLine : seq<string>
        member ExposeReturnCode : bool
        member SummaryFormat : System.String
        member Verbosity : System.Diagnostics.TraceLevel
        member Validate : afterPreparation:bool -> string []
      end

Validate does simple checking of the arguments without causing any changes to the system; set the input argument true if the Prepare step has already run (and there should be instrumented code the RecorderDirectory; returns all the problems that the application command-line could report, so empty is success.

The property members corresponding to the command line options read the values from the contained instance; null strings will be retrurned as null, but null sequences will be returned as empty ones.

Values that are not applicable to the use case or platform are silently ignored.

type PrepareOptions

The members correspond to the like-named command line options for AltCover, except

    [<NoComparison>]
    type PrepareOptions =
      | Primitive of Primitive.PrepareOptions
      | TypeSafe of TypeSafe.PrepareOptions
      | Abstract of Abstract.IPrepareOptions
      with
        interface Abstract.IPrepareOptions
        member InputDirectories : System.String list
        member OutputDirectories : System.String list
        member SymbolDirectories : System.String list
        member Dependencies : System.String list
        member Keys : System.String list
        member StrongNameKey : System.String
        member Report : System.String
        member FileFilter : System.String list
        member AssemblyFilter : System.String list
        member AssemblyExcludeFilter : System.String list
        member TypeFilter : System.String list
        member MethodFilter : System.String list
        member AttributeFilter : System.String list
        member PathFilter : System.String list
        member AttributeTopLevel : System.String list
        member TypeTopLevel : System.String list
        member MethodTopLevel : System.String list
        member CallContext : System.String list
        member ReportFormat : string
        member InPlace : bool
        member Save : bool
        member ZipFile : bool
        member MethodPoint : bool
        member SingleVisit : bool
        member LineCover : bool
        member BranchCover : bool
        member CommandLine : seq<System.String>
        member ExposeReturnCode : bool
        member SourceLink : bool
        member Defer : bool
        member LocalSource : bool
        member VisibleBranches : bool
        member ShowStatic : string
        member ShowGenerated : bool
        member Verbosity : System.Diagnostics.TraceLevel
        member Trivia: bool with get
        member OutputRoot : string with get
        member Portable : bool with get
        member Validate : unit -> string []
      end

Validate does simple checking of the arguments without causing any changes to the system; returns all the problems that the application command-line could report, so empty is success.

The property members corresponding to the command line options read the values from the contained instance; null strings will be retrurned as null, but null sequences will be returned as empty ones.

Values that are not applicable to the use case or platform are silently ignored.

type LoggingOptions

Destinations for user level output at various levels of success. Echo is for the command line and usage warninings only.

    type LoggingOptions =
      | Primitive of Primitive.LoggingOptions
      | Abstract of Abstract.ILoggingOptions
      with
        member Info : (System.String -> unit)
        member Warn : (System.String -> unit)
        member Error : (System.String -> unit)
        member Verbose : (System.String -> unit)
        member Echo : (System.String -> unit)
        static member Create : unit -> LoggingOptions
        static member Translate : options:Abstract.ILoggingOptions -> LoggingOptions
        static member ActionAdapter : action:System.Action<System.String> ->
                            (System.String -> unit)
      end

Of the static methods, Create() returns a pure sink instance; while ActionAdapter and Translate are helpers for C# use. The instance methods return the corresponding value from the underlying structure, translating Failure to Error (not a keyword in F#)