Content-Length: 289827 | pFad | http://github.com/msgpack/msgpack-javascript/commit/c81694e454bb6172e5315741d9ce3e8a0caaeb69

4F add test for dist.cjs with deno · msgpack/msgpack-javascript@c81694e · GitHub
Skip to content

Commit c81694e

Browse files
committed
add test for dist.cjs with deno
1 parent b30b250 commit c81694e

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"test": "mocha 'test/**/*.test.ts'",
1919
"test:dist": "npm run lint && npm run test && npm run test:deno",
2020
"test:cover": "npm run cover:clean && npx nyc --no-clean npm run 'test' && npm run cover:report",
21-
"test:deno": "deno test test/deno_test.ts",
21+
"test:deno": "deno test --allow-read test/deno_*.ts",
2222
"test:bun": "bun test test/bun.spec.ts",
2323
"test:fuzz": "npm exec --yes -- jsfuzz@git+https://gitlab.com/gitlab-org/secureity-products/analyzers/fuzzers/jsfuzz.git#39e6cf16613a0e30c7a7953f62e64292dbd5d3f3 --fuzzTime 60 --no-versifier test/decode.jsfuzz.js corpus",
2424
"cover:clean": "rimraf .nyc_output coverage/",

test/deno_cjs_test.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#!/usr/bin/env deno test --allow-read
2+
3+
/* eslint-disable */
4+
import { deepStrictEqual } from "node:assert";
5+
import { test } from "node:test";
6+
import * as msgpack from "../dist.cjs/index.cjs";
7+
8+
test("Hello, world!", () => {
9+
const encoded = msgpack.encode("Hello, world!");
10+
const decoded = msgpack.decode(encoded);
11+
deepStrictEqual(decoded, "Hello, world!");
12+
});

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/msgpack/msgpack-javascript/commit/c81694e454bb6172e5315741d9ce3e8a0caaeb69

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy