summaryrefslogtreecommitdiff
path: root/testing/test.ts
diff options
context:
space:
mode:
Diffstat (limited to 'testing/test.ts')
-rw-r--r--testing/test.ts7
1 files changed, 7 insertions, 0 deletions
diff --git a/testing/test.ts b/testing/test.ts
index 1765fd6b6..347a31b56 100644
--- a/testing/test.ts
+++ b/testing/test.ts
@@ -31,6 +31,13 @@ test(function testingAssertEqual() {
assert(assertEqual === assert.equal);
});
+test(function testingAssertFail() {
+ let didThrow = false;
+
+ assert.throws(assert.fail, Error, "Failed assertion.");
+ assert.throws(() => { assert.fail("foo"); }, Error, "Failed assertion: foo");
+});
+
test(function testingAssertEqualActualUncoercable() {
let didThrow = false;
const a = Object.create(null);