mirror of
https://github.com/lifegpc/eh-downloader.git
synced 2026-07-08 01:31:00 +08:00
Fix ffi database return big int
This commit is contained in:
@@ -12,6 +12,7 @@ import {
|
||||
PromiseStatus,
|
||||
sleep,
|
||||
sure_dir,
|
||||
toJSON,
|
||||
} from "./utils.ts";
|
||||
import { md5 } from "lifegpc-md5";
|
||||
|
||||
@@ -158,3 +159,11 @@ Deno.test("map_test", () => {
|
||||
}, d);
|
||||
assertEquals(re, [3, 4]);
|
||||
});
|
||||
|
||||
Deno.test("toJSON_test", () => {
|
||||
assertEquals(toJSON({ a: 3n }), '{"a":3}');
|
||||
assertEquals(
|
||||
toJSON([1099511627776n, { a: 45n }]),
|
||||
'[1099511627776,{"a":45}]',
|
||||
);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user