Skip to content

Commit 3aa73ed

Browse files
committed
fix: shacl shapes
1 parent f6c949f commit 3aa73ed

File tree

6 files changed

+274
-310
lines changed

6 files changed

+274
-310
lines changed

reproschema/tests/contexts/base

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"xsd": "http://www.w3.org/2001/XMLSchema#",
1111
"skos": "http://www.w3.org/2004/02/skos/core#",
1212
"prov": "http://www.w3.org/ns/prov#",
13+
"pav": "http://purl.org/pav/",
1314
"nidm": "http://purl.org/nidash/nidm#",
1415
"reproschema": "http://schema.repronim.org/"
1516
}

reproschema/tests/contexts/generic

Lines changed: 22 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@
33
{
44
"@version": 1.1,
55
"@language": "en",
6-
"schema:description": {
7-
"@container": "@language"
8-
},
96
"description": {
107
"@id": "schema:description",
118
"@container": "@language"
@@ -18,28 +15,20 @@
1815
"@id": "schema:value",
1916
"@container": "@language"
2017
},
21-
"schema:name": {
22-
"@container": "@language"
23-
},
24-
"schema:value": {
25-
"@container": "@language"
26-
},
27-
"schema:image": {
18+
"image": {
19+
"@id": "schema:image",
2820
"@type": "@vocab"
2921
},
30-
"schema:citation": {
31-
"@container": "@language"
32-
},
33-
"schema:version": {
34-
"@container": "@language"
35-
},
36-
"schema:schemaVersion": {
22+
"citation": {
23+
"@id": "schema:citation",
3724
"@container": "@language"
3825
},
39-
"skos:prefLabel": {
26+
"version": {
27+
"@id": "schema:version",
4028
"@container": "@language"
4129
},
42-
"skos:altLabel": {
30+
"schemaVersion": {
31+
"@id": "schema:schemaVersion",
4332
"@container": "@language"
4433
},
4534
"prefLabel": {
@@ -60,7 +49,7 @@
6049
},
6150
"landingPage": {
6251
"@id": "reproschema:landingPage",
63-
"@container": "@language"
52+
"@container": "@set"
6453
},
6554
"question": {
6655
"@id": "schema:question",
@@ -69,14 +58,6 @@
6958
"choices": {
7059
"@id": "schema:itemListElement"
7160
},
72-
"choiceUrl": {
73-
"@id": "schema:DigitalDocument",
74-
"@type": "@id"
75-
},
76-
"requiredValue": {
77-
"@id": "reproschema:requiredValue",
78-
"@type": "schema:Boolean"
79-
},
8061
"valueRequired": "https://schema.org/valueRequired",
8162
"multipleChoice": {
8263
"@id": "reproschema:multipleChoice",
@@ -105,7 +86,7 @@
10586
},
10687
"addProperties": {
10788
"@id": "reproschema:addProperties",
108-
"@type": "reproschema:AddProperties",
89+
"@type": "reproschema:AdditionalProperty",
10990
"@container": "@set",
11091
"@nest": "ui"
11192
},
@@ -124,12 +105,10 @@
124105
"@type": "xsd:string",
125106
"@nest": "ui"
126107
},
127-
"readOnly": {
128-
"@id": "reproschema:readOnly",
129-
"@type": "xsd:boolean",
108+
"readonlyValue": {
109+
"@id": "https://schema.org/readonlyValue",
130110
"@nest": "ui"
131111
},
132-
"readonlyValue": "https://schema.org/readonlyValue",
133112
"scoringLogic": {
134113
"@id": "reproschema:scoringLogic",
135114
"@container": "@index"
@@ -140,28 +119,24 @@
140119
"isVis": {
141120
"@id": "reproschema:isVis"
142121
},
143-
"required": {
144-
"@id": "reproschema:required",
145-
"@container": "@index",
146-
"@nest": "ui"
147-
},
148122
"variableName": "reproschema:variableName",
149123
"isAbout": {
150124
"@id": "reproschema:isAbout",
151125
"@type": "@id"
152126
},
153127
"allow": {
154128
"@id": "reproschema:allow",
155-
"@container": "@list",
129+
"@container": "@set",
156130
"@type": "@id",
157131
"@nest": "ui"
158132
},
159-
"skipped": "reproschema:Skipped",
160-
"dontKnow": "reproschema:DontKnow",
161-
"timedOut": "reproschema:TimedOut",
162-
"autoAdvance": "reproschema:AutoAdvance",
163-
"disableBack": "reproschema:DisableBack",
164-
"allowExport": "reproschema:AllowExport",
133+
"reproschema:Skipped": {"@id": "reproschema:Skipped"},
134+
"reproschema:DontKnow": {"@id": "reproschema:DontKnow"},
135+
"reproschema:TimedOut": {"@id": "reproschema:TimedOut"},
136+
"reproschema:AutoAdvance": {"@id": "reproschema:AutoAdvance"},
137+
"reproschema:DisableBack": {"@id": "reproschema:DisableBack"},
138+
"reproschema:AllowExport": {"@id": "reproschema:AllowExport"},
139+
"reproschema:AllowReplay": {"@id": "reproschema:AllowReplay"},
165140
"timer": {
166141
"@id": "reproschema:timer",
167142
"@type": "@id",
@@ -190,15 +165,15 @@
190165
},
191166
"createdOn": {
192167
"@id": "pav:createdOn",
193-
"@type": "xsd:date"
168+
"@type": "xsd:dateTime"
194169
},
195170
"previousVersion": {
196171
"@id": "pav:previousVersion",
197172
"@type": "@id"
198173
},
199174
"lastUpdateOn": {
200175
"@id": "pav:lastUpdateOn",
201-
"@type": "xsd:date"
176+
"@type": "xsd:dateTime"
202177
},
203178
"derivedFrom": {
204179
"@id": "prov:wasDerivedFrom",

reproschema/tests/data/activities/activity1.jsonld

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
"@context": "../../contexts/generic",
33
"@type": "reproschema:Activity",
44
"@id": "activity1.jsonld",
5-
"skos:prefLabel": "Example 1",
6-
"schema:description": "Activity example 1",
7-
"schema:schemaVersion": "0.0.1",
8-
"schema:version": "0.0.1",
9-
"schema:citation": "https://www.ncbi.nlm.nih.gov/pmc/articles/PMC1495268/",
5+
"prefLabel": "Example 1",
6+
"description": "Activity example 1",
7+
"schemaVersion": "0.0.1",
8+
"version": "0.0.1",
9+
"citation": "https://www.ncbi.nlm.nih.gov/pmc/articles/PMC1495268/",
1010
"preamble": {
1111
"en": "Over the last 2 weeks, how often have you been bothered by any of the following problems?",
1212
"es": "Durante las últimas 2 semanas, ¿con qué frecuencia le han molestado los siguintes problemas?"

reproschema/tests/data/activities/items/item1.jsonld

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
"@context": "../../../contexts/generic",
33
"@type": "reproschema:Field",
44
"@id": "item1.jsonld",
5-
"skos:prefLabel": "item1",
6-
"schema:description": "Q1 of example 1",
7-
"schema:schemaVersion": "0.0.1",
8-
"schema:version": "0.0.1",
5+
"prefLabel": "item1",
6+
"description": "Q1 of example 1",
7+
"schemaVersion": "0.0.1",
8+
"version": "0.0.1",
99
"question": {
1010
"en": "Little interest or pleasure in doing things",
1111
"es": "Poco interés o placer en hacer cosas"
@@ -15,8 +15,8 @@
1515
},
1616
"responseOptions": {
1717
"valueType": "xsd:integer",
18-
"schema:minValue": 0,
19-
"schema:maxValue": 3,
18+
"minValue": 0,
19+
"maxValue": 3,
2020
"multipleChoice": false,
2121
"choices": [
2222
{

reproschema/tests/data/protocols/protocol1.jsonld

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@
66
"en": "Protocol1",
77
"es": "Protocol1_es"
88
},
9-
"schema:description": "example Protocol",
10-
"schema:schemaVersion": "0.0.1",
11-
"schema:version": "0.0.1",
9+
"description": "example Protocol",
10+
"schemaVersion": "0.0.1",
11+
"version": "0.0.1",
1212
"ui": {
1313
"addProperties": [
1414
{
15-
"isAbout": "activities/activity1.jsonld",
15+
"isAbout": "../activities/activity1.jsonld",
1616
"variableName": "activity1",
1717
"prefLabel": {
1818
"en": "Screening",
@@ -22,13 +22,13 @@
2222
}
2323
],
2424
"order": [
25-
"activities/activity1.jsonld"
25+
"../activities/activity1.jsonld"
2626
],
2727
"shuffle": false,
2828
"allow": [
29-
"autoAdvance",
30-
"disableBack",
31-
"allowExport"
29+
"reproschema:AutoAdvance",
30+
"reproschema:DisableBack",
31+
"reproschema:AllowExport"
3232
]
3333
}
3434
}

0 commit comments

Comments
 (0)