mirror of
https://github.com/privacy-scaling-explorations/emp-wasm.git
synced 2026-01-09 01:57:54 -05:00
chore: test code from src
This commit is contained in:
8
package-lock.json
generated
8
package-lock.json
generated
@@ -9,7 +9,7 @@
|
|||||||
"version": "0.1.7",
|
"version": "0.1.7",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"ee-typed": "^0.1.0",
|
"ee-typed": "^0.1.1",
|
||||||
"events": "^3.3.0"
|
"events": "^3.3.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
@@ -964,9 +964,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/ee-typed": {
|
"node_modules/ee-typed": {
|
||||||
"version": "0.1.0",
|
"version": "0.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/ee-typed/-/ee-typed-0.1.0.tgz",
|
"resolved": "https://registry.npmjs.org/ee-typed/-/ee-typed-0.1.1.tgz",
|
||||||
"integrity": "sha512-tLlZ5IrB0KGJYTtqawcyY5Bl7T3ssUyq1huccSrj1X8qlSdStu0D+ShzMZaZOQubxnPXFMhjcB2+RKJqeYu00Q==",
|
"integrity": "sha512-atfgRdyoqK/QOY7dqv4jwAi7th45DDX2zRjGgLR8zRgJy7QSLyoS6aI1jZbKf/VIrXy9YTpHFCr8Mzxj//a/KA==",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/node": "^20.14.2",
|
"@types/node": "^20.14.2",
|
||||||
"typed-emitter": "^2.1.0"
|
"typed-emitter": "^2.1.0"
|
||||||
|
|||||||
@@ -27,7 +27,7 @@
|
|||||||
"ws": "^8.18.0"
|
"ws": "^8.18.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"ee-typed": "^0.1.0",
|
"ee-typed": "^0.1.1",
|
||||||
"events": "^3.3.0"
|
"events": "^3.3.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -20,8 +20,7 @@ export default async function nodeSecure2PC(
|
|||||||
throw new Error('Not running in Node.js');
|
throw new Error('Not running in Node.js');
|
||||||
}
|
}
|
||||||
|
|
||||||
// @ts-ignore
|
let Module = await (await import('../../build/jslib.js')).default();
|
||||||
let Module = await (await import('../../../build/jslib.js')).default();
|
|
||||||
|
|
||||||
if (Module.emp) {
|
if (Module.emp) {
|
||||||
throw new Error('Can only run one secure2PC at a time');
|
throw new Error('Can only run one secure2PC at a time');
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import { expect } from 'chai';
|
import { expect } from 'chai';
|
||||||
import { BufferQueue, secure2PC } from "../"
|
import { BufferQueue, secure2PC } from "../src/ts"
|
||||||
|
|
||||||
describe('Secure 2PC', () => {
|
describe('Secure 2PC', () => {
|
||||||
it('3 + 5 == 8', async () => {
|
it('3 + 5 == 8', async () => {
|
||||||
|
|||||||
@@ -106,5 +106,6 @@
|
|||||||
// "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */
|
// "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */
|
||||||
"skipLibCheck": true /* Skip type checking all .d.ts files. */
|
"skipLibCheck": true /* Skip type checking all .d.ts files. */
|
||||||
},
|
},
|
||||||
"include": ["tests", "src/ts"]
|
"include": ["tests", "src/ts"],
|
||||||
|
"exclude": ["tests"]
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user