summaryrefslogtreecommitdiff
path: root/js/timers_test.ts
diff options
context:
space:
mode:
Diffstat (limited to 'js/timers_test.ts')
-rw-r--r--js/timers_test.ts11
1 files changed, 10 insertions, 1 deletions
diff --git a/js/timers_test.ts b/js/timers_test.ts
index 65432d4c5..76563c96e 100644
--- a/js/timers_test.ts
+++ b/js/timers_test.ts
@@ -1,5 +1,5 @@
// Copyright 2018-2019 the Deno authors. All rights reserved. MIT license.
-import { test, assert, assertEquals } from "./test_util.ts";
+import { test, assert, assertEquals, assertNotEquals } from "./test_util.ts";
function deferred(): {
promise: Promise<{}>;
@@ -243,3 +243,12 @@ test(async function clearTimeoutShouldConvertToNumber(): Promise<void> {
clearTimeout((obj as unknown) as number);
assert(called);
});
+
+test(function testFunctionName(): void {
+ assertEquals(clearTimeout.name, "clearTimeout");
+ assertEquals(clearInterval.name, "clearInterval");
+});
+
+test(function clearTimeoutAndClearIntervalNotBeEquals(): void {
+ assertNotEquals(clearTimeout, clearInterval);
+});