Skip to content

Commit

Permalink
Fix id proof tests
Browse files Browse the repository at this point in the history
  • Loading branch information
DOBEN committed Sep 12, 2024
1 parent a4b33c6 commit 32ba954
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
8 changes: 7 additions & 1 deletion packages/sdk/src/id/idProofTypes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,10 @@ export const attributesWithRange: AttributeKey[] = ['dob', 'idDocIssuedAt', 'idD
/**
* The attributes that can be used for (non)membership statements
*/
export const attributesWithSet: AttributeKey[] = ['countryOfResidence', 'nationality', 'idDocType', 'idDocIssuer'];
export const attributesWithSet: AttributeKey[] = [
'countryOfResidence',
'nationality',
'idDocType',
'idDocIssuer',
'legalCountry',
];
2 changes: 1 addition & 1 deletion packages/sdk/test/ci/idProofs.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ test('Upper bound must be greater than lower bound for attribute statement', ()
test('Unknown attribute tags are rejected', () => {
const builder = new IdStatementBuilder(true);
expect(() => builder.addMembership(-1 as unknown as AttributesKeys, ['DK'])).toThrow();
expect(() => builder.addMembership(15 as unknown as AttributesKeys, ['DK'])).toThrow();
expect(() => builder.addMembership(16 as unknown as AttributesKeys, ['DK'])).toThrow();
expect(() => builder.addMembership(1000 as unknown as AttributesKeys, ['DK'])).toThrow();
});

Expand Down

0 comments on commit 32ba954

Please sign in to comment.