1
0
Fork 0
mirror of https://github.com/kou029w/_.git synced 2025-01-31 06:18:07 +00:00
_/node-test/parse-json.test.js
2022-08-19 23:19:48 +09:00

8 lines
241 B
JavaScript

import { test } from "node:test";
import assert from "node:assert/strict";
test("parse json", () => {
const json = `{"name": "太郎", "age": 42}`;
const obj = JSON.parse(json);
assert.deepEqual(obj, { name: "太郎", age: 42 });
});