File tree 2 files changed +13
-1
lines changed
Filter options
2 files changed +13
-1
lines changed
Original file line number Diff line number Diff line change 18
18
"test" : " mocha 'test/**/*.test.ts'" ,
19
19
"test:dist" : " npm run lint && npm run test && npm run test:deno" ,
20
20
"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" ,
22
22
"test:bun" : " bun test test/bun.spec.ts" ,
23
23
"test:fuzz" : " npm exec --yes -- jsfuzz@git+https://gitlab.com/gitlab-org/security-products/analyzers/fuzzers/jsfuzz.git#39e6cf16613a0e30c7a7953f62e64292dbd5d3f3 --fuzzTime 60 --no-versifier test/decode.jsfuzz.js corpus" ,
24
24
"cover:clean" : " rimraf .nyc_output coverage/" ,
Original file line number Diff line number Diff line change
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
+ } ) ;
You can’t perform that action at this time.
0 commit comments