dunit.assertion

Undocumented in source.

Members

Aliases

assertGreaterThan
alias assertGreaterThan = assertOp!">"
Undocumented in source.
assertGreaterThanOrEqual
alias assertGreaterThanOrEqual = assertOp!">="
Undocumented in source.
assertIn
alias assertIn = assertOp!"in"
Undocumented in source.
assertLessThan
alias assertLessThan = assertOp!"<"
Undocumented in source.
assertLessThanOrEqual
alias assertLessThanOrEqual = assertOp!"<="
Undocumented in source.
assertNotIn
alias assertNotIn = assertOp!"!in"
Undocumented in source.

Classes

AssertAllException
class AssertAllException

Thrown on an assertion failure.

AssertException
class AssertException

Thrown on an assertion failure.

Functions

assertAll
void assertAll(void delegate() @(safe[]) assertions)

Asserts that all assertions pass.

assertArrayEquals
void assertArrayEquals(T[] expected, U[] actual, string msg, string file, size_t line)

Asserts that the arrays are equal.

assertArrayEquals
void assertArrayEquals(T[V] expected, U[V] actual, string msg, string file, size_t line)

Asserts that the associative arrays are equal.

assertEmpty
void assertEmpty(T actual, string msg, string file, size_t line)

Asserts that the value is empty.

assertEquals
void assertEquals(T expected, U actual, string msg, string file, size_t line)

Asserts that the string values are equal.

assertEquals
void assertEquals(T expected, U actual, string msg, string file, size_t line)

Asserts that the floating-point values are approximately equal.

assertEquals
void assertEquals(T expected, U actual, string msg, string file, size_t line)

Asserts that the values are equal.

assertFalse
void assertFalse(T condition, string msg, string file, size_t line)

Asserts that a condition is false.

assertNotEmpty
void assertNotEmpty(T actual, string msg, string file, size_t line)

Asserts that the value is not empty.

assertNotNull
void assertNotNull(T actual, string msg, string file, size_t line)

Asserts that the value is not null.

assertNotSame
void assertNotSame(T expected, U actual, string msg, string file, size_t line)

Asserts that the values are not the same.

assertNull
void assertNull(T actual, string msg, string file, size_t line)

Asserts that the value is null.

assertRangeEquals
void assertRangeEquals(R1 expected, R2 actual, string msg, string file, size_t line)

Asserts that the ranges are equal.

assertSame
void assertSame(T expected, U actual, string msg, string file, size_t line)

Asserts that the values are the same.

assertTrue
void assertTrue(T condition, string msg, string file, size_t line)

Asserts that a condition is true.

description
string description(Throwable throwable)

Returns a description of the throwable.

expectThrows
T expectThrows(E expression, string msg, string file, size_t line)

Asserts that the expression throws the specified throwable.

fail
void fail(string msg, string file, size_t line)

Fails a test.

Static functions

assertEventually
void assertEventually(bool delegate() probe, Duration timeout, Duration delay, string msg, string file, size_t line)

Checks a probe until the timeout expires. The assert error is produced if the probe fails to return 'true' before the timeout.

Templates

assertOp
template assertOp(string op)

Asserts that the condition (lhs op rhs) is satisfied.

Meta