diff options
Diffstat (limited to 'tests/unit_node/v8_test.ts')
-rw-r--r-- | tests/unit_node/v8_test.ts | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/unit_node/v8_test.ts b/tests/unit_node/v8_test.ts index c9697c870..b91d595db 100644 --- a/tests/unit_node/v8_test.ts +++ b/tests/unit_node/v8_test.ts @@ -1,7 +1,9 @@ // Copyright 2018-2024 the Deno authors. All rights reserved. MIT license. import { cachedDataVersionTag, + deserialize, getHeapStatistics, + serialize, setFlagsFromString, } from "node:v8"; import { assertEquals } from "@std/assert/mod.ts"; @@ -53,3 +55,12 @@ Deno.test({ setFlagsFromString("--allow_natives_syntax"); }, }); + +Deno.test({ + name: "serialize deserialize", + fn() { + const s = serialize({ a: 1 }); + const d = deserialize(s); + assertEquals(d, { a: 1 }); + }, +}); |