C# Class Xunit.Assert

Mostrar archivo Open project: docevaad/Chain Class Usage Examples

Public Methods

Method Description
False ( bool condition ) : void

Verifies that the condition is false.

False ( bool condition, string userMessage ) : void

Verifies that the condition is false.

IsFalse ( bool condition, string userMessage ) : void
IsTrue ( bool condition, string userMessage ) : void
NotNull ( object @object, string userMessage ) : void

Verifies that an object reference is not null.

Null ( object @object, string userMessage ) : void

Verifies that an object reference is null.

True ( bool condition ) : void

Verifies that an expression is true.

True ( bool condition, string userMessage ) : void

Verifies that an expression is true.

Private Methods

Method Description
IsNull ( object @object, string userMessage ) : void
RecordException ( System.Action testCode ) : Exception
RecordException ( Func testCode ) : Exception
RecordException ( Func testCode ) : Exception
RecordExceptionAsync ( Func testCode ) : Task

Method Details

False() public static method

Verifies that the condition is false.
Thrown if the condition is not false
public static False ( bool condition ) : void
condition bool The condition to be tested
return void

False() public static method

Verifies that the condition is false.
Thrown if the condition is not false
public static False ( bool condition, string userMessage ) : void
condition bool The condition to be tested
userMessage string The message to show when the condition is not false
return void

IsFalse() public static method

public static IsFalse ( bool condition, string userMessage ) : void
condition bool
userMessage string
return void

IsTrue() public static method

public static IsTrue ( bool condition, string userMessage ) : void
condition bool
userMessage string
return void

NotNull() public static method

Verifies that an object reference is not null.
Thrown when the object is not null
public static NotNull ( object @object, string userMessage ) : void
@object object
userMessage string
return void

Null() public static method

Verifies that an object reference is null.
Thrown when the object reference is not null
public static Null ( object @object, string userMessage ) : void
@object object
userMessage string
return void

True() public static method

Verifies that an expression is true.
Thrown when the condition is false
public static True ( bool condition ) : void
condition bool The condition to be inspected
return void

True() public static method

Verifies that an expression is true.
Thrown when the condition is false
public static True ( bool condition, string userMessage ) : void
condition bool The condition to be inspected
userMessage string The message to be shown when the condition is false
return void