AssertException otherwise
assertEquals(42, 42); auto exception = expectThrows!AssertException(assertEquals(42, 24)); assertEquals("expected: <42> but was: <24>", exception.msg);
Object foo = new Object(); Object bar = null; assertEquals(foo, foo); assertEquals(bar, bar); auto exception = expectThrows!AssertException(assertEquals(foo, bar)); assertEquals("expected: <object.Object> but was: <null>", exception.msg);
Asserts that the values are equal.