s&box docs
API ReferenceSandbox.Diagnostics

public static abstract sealed class Sandbox.Diagnostics.Assert

Broader workflow and conceptual references connected to this API.

Methods

Showing 9 methods

public static void AreEqual(T a, T b, string message = null)

Throws an exception when the 2 given objects are not equal to each other.

Parameters

  • a: Object A to test.
  • b: Object B to test.
  • message: Message to include in the exception, if any. Default: null

Exceptions

ExceptionCondition
ExceptionThrown when 2 given objects are not equal

public static void AreNotEqual(T a, T b, string message = null)

Throws an exception when the 2 given objects are equal to each other.

Parameters

  • message: Default: null

public static void False(bool isValid, string message = null)

Throws an exception when given expression does not resolve to false.

Parameters

  • isValid: The expression to test
  • message: Message to include in the exception, if any. Default: null

Exceptions

ExceptionCondition
ExceptionThrown when given expression is not false.

public static void IsValid(Sandbox.IValid obj)

Throws an exception when the given object is not valid.

public static void True(bool isValid, string message = null)

Throws an exception when given expression does not resolve to true.

Parameters

  • isValid: The expression to test
  • message: Message to include in the exception, if any. Default: null

Exceptions

ExceptionCondition
ExceptionThrown when given expression is not true.

Metadata

FieldValue
NamespaceSandbox.Diagnostics
Typeclass
AssemblySandbox.System
Doc IDT:Sandbox.Diagnostics.Assert

On this page