File tree Expand file tree Collapse file tree 2 files changed +39
-1
lines changed Expand file tree Collapse file tree 2 files changed +39
-1
lines changed Original file line number Diff line number Diff line change
1
+ /*!
2
+ * Copyright 2024 Digital Bazaar, Inc.
3
+ * SPDX-License-Identifier: BSD-3-Clause
4
+ */
5
+ import { dataModelSuite } from './suites/data-model.js' ;
6
+ import { endpoints } from 'vc-test-suite-implementations' ;
7
+ import { getSuiteConfig } from './test-config.js' ;
8
+
9
+ const cryptosuites = [
10
+ 'ecdsa-rdfc-2019' ,
11
+ 'ecdsa-jcs-2019'
12
+ ] ;
13
+
14
+ for ( const suiteName of cryptosuites ) {
15
+ const { tags, credentials, vectors} = getSuiteConfig ( suiteName ) ;
16
+ const { match : issuers } = endpoints . filterByTag ( {
17
+ tags : [ ...tags ] ,
18
+ property : 'issuers'
19
+ } ) ;
20
+ for ( const vcVersion of vectors . vcTypes ) {
21
+ const {
22
+ document,
23
+ mandatoryPointers,
24
+ selectivePointers
25
+ } = credentials . create [ vcVersion ] ;
26
+ for ( const keyType of vectors . keyTypes ) {
27
+ dataModelSuite ( {
28
+ issuers,
29
+ suiteName,
30
+ keyType,
31
+ vcVersion,
32
+ credential : document ,
33
+ mandatoryPointers,
34
+ selectivePointers
35
+ } ) ;
36
+ }
37
+ }
38
+ }
Original file line number Diff line number Diff line change @@ -107,7 +107,7 @@ export function dataModelSuite({
107
107
for ( const proof of proofs ) {
108
108
expect ( proof . cryptosuite ) . to . exist ;
109
109
expect ( proof . cryptosuite ) . to . be . a ( 'string' ) ;
110
- expect ( proof . cryptosuite ) . to . oneOf (
110
+ expect ( proof . cryptosuite ) . to . be . oneOf (
111
111
[ 'eddsa-rdfc-2022' , 'eddsa-jcs-2022' ] ) ;
112
112
}
113
113
} ) ;
You can’t perform that action at this time.
0 commit comments