Note: This is the migration API reference for FAKE 5. The new (modularized) API documentation can be found here. If the API is already migrated you can check here if exists in a module. More information regarding the migration can be found here

OBSOLETE

use Fake.DotNet.Testing.XUnit2 instead

XUnit2

Contains tasks to run xUnit v2 unit tests.

Nested types and modules

TypeDescription
CollectionConcurrencyMode
OBSOLETE

use Fake.DotNet.Testing.XUnit2 instead

The collection concurrency mode used by the xUnit2 runner.

ParallelMode
OBSOLETE

use Fake.DotNet.Testing.XUnit2 instead

The parallelization mode of the xUnit2 runner.

XUnit2Params
OBSOLETE

use Fake.DotNet.Testing.XUnit2 instead

The xUnit2 parameter type.

Functions and values

Function or valueDescription
buildXUnit2Args assemblies parameters
Signature: assemblies:seq<string> -> parameters:XUnit2Params -> string
Attributes:
[<Obsolete("use Fake.DotNet.Testing.XUnit2 instead")>]
OBSOLETE

use Fake.DotNet.Testing.XUnit2 instead

xUnit2 setParams assemblies
Signature: setParams:(XUnit2Params -> XUnit2Params) -> assemblies:seq<string> -> unit
Attributes:
[<Obsolete("use Fake.DotNet.Testing.XUnit2 instead")>]
OBSOLETE

use Fake.DotNet.Testing.XUnit2 instead

Runs xUnit v2 unit tests in the given assemblies via the given xUnit2 runner. Will fail if the runner terminates with non-zero exit code.

The xUnit2 runner terminates with a non-zero exit code if any of the tests in the given assembly fail.

Parameters

  • setParams - Function used to manipulate the default XUnit2Params value.
  • assemblies - Sequence of one or more assemblies containing xUnit unit tests.

Sample usage

1: 
2: 
3: 
4: 
Target "Test" (fun _ ->
    !! (testDir @@ "xUnit.Test.*.dll")
    |> xUnit2 (fun p -> { p with HtmlOutputPath = Some (testDir @@ "xunit.html") })
)
union case Option.Some: Value: 'T -> Option<'T>
XUnit2Defaults
Signature: XUnit2Params
Attributes:
[<Obsolete("use Fake.DotNet.Testing.XUnit2 instead")>]
OBSOLETE

use Fake.DotNet.Testing.XUnit2 instead

The xUnit2 default parameters.

Defaults

  • NoAppDomain - false
  • Parallel - NoParallelization
  • MaxThreads - Default
  • HtmlOutputPath - None
  • XmlOutputPath - None
  • XmlV1OutputPath - None
  • IncludeTraits - []
  • ExcludeTraits - []
  • ShadowCopy - true
  • ErrorLevel - Error
  • ToolPath - The xunit.console.exe path if it exists in a subdirectory of the current directory.
  • WorkingDir - None
  • TimeOut - 5 minutes
  • ForceTeamCity - false
  • ForceAppVeyor - false
  • Silent - false
  • Wait - false
  • Namespace - None
  • Class - None
  • Method - None