Method IsNull
IsNull<T>(T)
Assert that a value is a null reference. Throws an exception if the assertion fails.
Declaration
[Conditional("UNITY_ASSERTIONS")]
public static void IsNull<T>(T value) where T : class
Parameters
Type | Name | Description |
---|---|---|
T | value | The value that the caller expects to be a null reference. |
Type Parameters
Name | Description |
---|---|
T | The type of the object being tested. |
IsNull<T>(T, string)
Assert that a value is a null reference. Throws an exception if the assertion fails.
Declaration
[Conditional("UNITY_ASSERTIONS")]
public static void IsNull<T>(T value, string message) where T : class
Parameters
Type | Name | Description |
---|---|---|
T | value | The value that the caller expects to be a null reference. |
string | message | If the assertion fails, this message will be logged. |
Type Parameters
Name | Description |
---|---|
T | The type of the object being tested. |