summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dispatch.ts2
-rw-r--r--testdata/004_set_timeout.ts4
-rw-r--r--tests.ts2
3 files changed, 4 insertions, 4 deletions
diff --git a/dispatch.ts b/dispatch.ts
index f6823ceff..01bd58bed 100644
--- a/dispatch.ts
+++ b/dispatch.ts
@@ -4,7 +4,7 @@ import { typedArrayToArrayBuffer } from "./util";
import { _global } from "./globals";
import { main as pb } from "./msg.pb";
-type MessageCallback = (msg: Uint8Array) => void;
+export type MessageCallback = (msg: Uint8Array) => void;
//type MessageStructCallback = (msg: pb.IMsg) => void;
const send = V8Worker2.send;
diff --git a/testdata/004_set_timeout.ts b/testdata/004_set_timeout.ts
index cc55bf76f..214b25086 100644
--- a/testdata/004_set_timeout.ts
+++ b/testdata/004_set_timeout.ts
@@ -1,10 +1,10 @@
-setTimeout(function() {
+setTimeout(() => {
console.log("World");
}, 10);
console.log("Hello");
-const id = setTimeout(function() {
+const id = setTimeout(() => {
console.log("Not printed");
}, 10000);
diff --git a/tests.ts b/tests.ts
index 45991228b..d4b188fda 100644
--- a/tests.ts
+++ b/tests.ts
@@ -20,7 +20,7 @@ test(async function tests_fetch() {
});
test(async function tests_readFileSync() {
- let data = readFileSync("package.json");
+ const data = readFileSync("package.json");
if (!data.byteLength) {
throw Error(
`Expected positive value for data.byteLength ${data.byteLength}`