AssertException otherwise
int[4] expected = [1, 2, 3, 4]; assertArrayEquals(expected, [1, 2, 3, 4]); AssertException exception; exception = expectThrows!AssertException(assertArrayEquals(expected, [1, 2])); assertEquals(`length mismatch; expected: <4> but was: <2>`, exception.msg); exception = expectThrows!AssertException(assertArrayEquals(expected, [1, 2, 5, 4])); assertEquals(`mismatch at index 2; expected: <3> but was: <5>`, exception.msg);
Asserts that the static arrays are equal.