diff options
author | Yoshiya Hinosawa <stibium121@gmail.com> | 2019-10-28 00:22:53 +0900 |
---|---|---|
committer | Ry Dahl <ry@tinyclouds.org> | 2019-10-27 11:22:53 -0400 |
commit | efd7e78af3fc086dfdec51738905665d38d08eb4 (patch) | |
tree | bb921f7d960f33c6d4d13c043a7a45ebe74290ba /cli/tests | |
parent | 2598f9c68d8983934c73c135c9d277b33c98e333 (diff) |
Use web standard Permissions API (#3200)
Diffstat (limited to 'cli/tests')
-rw-r--r-- | cli/tests/025_hrtime.ts | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/cli/tests/025_hrtime.ts b/cli/tests/025_hrtime.ts index 417ca6982..9f60b7a77 100644 --- a/cli/tests/025_hrtime.ts +++ b/cli/tests/025_hrtime.ts @@ -1,3 +1,5 @@ -console.log(performance.now() % 2 !== 0); -Deno.revokePermission("hrtime"); -console.log(performance.now() % 2 === 0); +window.onload = async (): Promise<void> => { + console.log(performance.now() % 2 !== 0); + await Deno.permissions.revoke({ name: "hrtime" }); + console.log(performance.now() % 2 === 0); +}; |