Skip to content

Commit 571234c

Browse files
committed
check issue credentials in issuer revocation keys
1 parent 60a0c50 commit 571234c

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

tests/handlers/auth.test.ts

+9
Original file line numberDiff line numberDiff line change
@@ -2206,6 +2206,10 @@ describe('auth', () => {
22062206
);
22072207
expect(issuerAuthCredential2).to.be.deep.equal(credential2);
22082208

2209+
// check we can issue new credential with k2
2210+
const issuerCred2 = await idWallet.issueCredential(issuerDID, claimReq);
2211+
expect(issuerCred2).to.be.not.undefined;
2212+
22092213
const treesModel2 = await idWallet.getDIDTreeModel(issuerDID);
22102214
const [ctrHex2, rtrHex2, rorTrHex2] = await Promise.all([
22112215
treesModel2.claimsTree.root(),
@@ -2230,6 +2234,11 @@ describe('auth', () => {
22302234
'no auth credentials found'
22312235
);
22322236

2237+
// check that we can't issue new credential
2238+
await expect(idWallet.issueCredential(issuerDID, claimReq)).to.rejectedWith(
2239+
'no auth credentials found'
2240+
);
2241+
22332242
// should this work?
22342243
await handleAuthorizationRequest(userDID, authReqBody);
22352244
});

0 commit comments

Comments
 (0)