summaryrefslogtreecommitdiff
path: root/js/read_file_test.ts
diff options
context:
space:
mode:
authorRyan Dahl <ry@tinyclouds.org>2019-04-21 16:40:10 -0400
committerGitHub <noreply@github.com>2019-04-21 16:40:10 -0400
commit9dfebbc9496138efbeedc431068f41662c780f3e (patch)
treec3718c3dc132d11c08c8fc18933daebf886bf787 /js/read_file_test.ts
parent6cded14bdf313762956d4d5361cfe8115628b535 (diff)
Fix eslint warnings (#2151)
Co-authored-by: Bartek IwaƄczuk <biwanczuk@gmail.com> Co-authored-by: LE GOFF Vincent <g_n_s@hotmail.fr>
Diffstat (limited to 'js/read_file_test.ts')
-rw-r--r--js/read_file_test.ts10
1 files changed, 5 insertions, 5 deletions
diff --git a/js/read_file_test.ts b/js/read_file_test.ts
index 2e0525d3f..7d4f4789c 100644
--- a/js/read_file_test.ts
+++ b/js/read_file_test.ts
@@ -1,7 +1,7 @@
// Copyright 2018-2019 the Deno authors. All rights reserved. MIT license.
import { testPerm, assert, assertEquals } from "./test_util.ts";
-testPerm({ read: true }, function readFileSyncSuccess() {
+testPerm({ read: true }, function readFileSyncSuccess(): void {
const data = Deno.readFileSync("package.json");
assert(data.byteLength > 0);
const decoder = new TextDecoder("utf-8");
@@ -10,7 +10,7 @@ testPerm({ read: true }, function readFileSyncSuccess() {
assertEquals(pkg.name, "deno");
});
-testPerm({ read: false }, function readFileSyncPerm() {
+testPerm({ read: false }, function readFileSyncPerm(): void {
let caughtError = false;
try {
Deno.readFileSync("package.json");
@@ -22,7 +22,7 @@ testPerm({ read: false }, function readFileSyncPerm() {
assert(caughtError);
});
-testPerm({ read: true }, function readFileSyncNotFound() {
+testPerm({ read: true }, function readFileSyncNotFound(): void {
let caughtError = false;
let data;
try {
@@ -35,7 +35,7 @@ testPerm({ read: true }, function readFileSyncNotFound() {
assert(data === undefined);
});
-testPerm({ read: true }, async function readFileSuccess() {
+testPerm({ read: true }, async function readFileSuccess(): Promise<void> {
const data = await Deno.readFile("package.json");
assert(data.byteLength > 0);
const decoder = new TextDecoder("utf-8");
@@ -44,7 +44,7 @@ testPerm({ read: true }, async function readFileSuccess() {
assertEquals(pkg.name, "deno");
});
-testPerm({ read: false }, async function readFilePerm() {
+testPerm({ read: false }, async function readFilePerm(): Promise<void> {
let caughtError = false;
try {
await Deno.readFile("package.json");