Skip to content

Commit

Permalink
Await bbs keyDoc.
Browse files Browse the repository at this point in the history
  • Loading branch information
aljones15 committed Jul 21, 2024
1 parent c46823d commit 7496bfb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
7 changes: 2 additions & 5 deletions test/10-verify.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,19 +89,17 @@ function _runSuite({
const {
createDiscloseCryptosuite,
createSignCryptosuite,
createVerifyCryptosuite
} = cryptosuite;
const proofId = `urn:uuid:${uuid()}`;
const mandatoryPointers = (version === 1.0) ?
['/issuer', '/issuanceDate'] : ['/issuer'];
// setup ecdsa-sd-2023 suite for signing selective disclosure VCs
const sdSignSuite = new DataIntegrityProof({
signer: keyPair.signer(), cryptosuite: createSignCryptosuite({
signer: keyPair.signer(),
cryptosuite: createSignCryptosuite({
mandatoryPointers
})
});
sdSignSuite.proof = {id: proofId};
// setup ecdsa-sd-2023 suite for deriving selective disclosure VCs
const sdDeriveSuite = new DataIntegrityProof({
cryptosuite: createDiscloseCryptosuite({
proofId,
Expand All @@ -127,7 +125,6 @@ function _runSuite({
suite: verifySuite,
documentLoader
});

if(result.error) {
throw result.error;
}
Expand Down
2 changes: 1 addition & 1 deletion test/mocks/suites.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ async function bbs2023() {
id: 'https://example.edu/issuers/keys/2',
controller: 'https://example.edu/issuers/565049'
});
const keyDoc = keyPair.export({publicKey: true});
const keyDoc = await keyPair.export({publicKey: true});
registerKey({keyDoc});
return {
keyDoc,
Expand Down

0 comments on commit 7496bfb

Please sign in to comment.