Multithread

This commit is contained in:
Jordi Baylina 2019-12-20 21:55:07 +01:00
parent bc0fb60f89
commit 756f1f51e5
No known key found for this signature in database
GPG Key ID: 7480C80C1BE43112
2 changed files with 10 additions and 3 deletions

@ -1 +1,2 @@
{ "in": ["0", "0"]}
{"enabled":1,"Ax":"13277427435165878497778222415993513565335242147425444199013288855685581939618","Ay":"13622229784656158136036771217484571176836296686641868549125388198837476602820","R8x":"11220723668893468001994760120794694848178115379170651044669708829805665054484","R8y":"2367470421002446880004241260470975644531657398480773647535134774673409612366","S":"1307100909096544936550139783786226891472336052773077686618468233418583414320","M":"1234"}

@ -2,6 +2,7 @@ const chai = require("chai");
const path = require("path");
const bigInt = require("big-integer");
const tester = require("circom").tester;
const utils = require("../src/utils");
const eddsa = require("../src/eddsa.js");
@ -29,14 +30,19 @@ describe("EdDSA Poseidon test", function () {
assert(eddsa.verifyPoseidon(msg, signature, pubKey));
const w = await circuit.calculateWitness({
const input = {
enabled: 1,
Ax: pubKey[0],
Ay: pubKey[1],
R8x: signature.R8[0],
R8y: signature.R8[1],
S: signature.S,
M: msg});
M: msg
};
// console.log(JSON.stringify(utils.stringifyBigInts(input)));
const w = await circuit.calculateWitness(input);
await circuit.checkConstraints(w);
});