diff --git a/shapes/skohub.shacl.ttl b/shapes/skohub.shacl.ttl index eb148af..de8d7cd 100644 --- a/shapes/skohub.shacl.ttl +++ b/shapes/skohub.shacl.ttl @@ -9,6 +9,7 @@ @prefix dct: . @prefix sdo: . @prefix vann: . +@prefix dc: . # rdfs:comment holds info with what file under ./tests/invalid/skohub.shacl.ttl # the constraint is tested @@ -17,14 +18,32 @@ :ConceptSchemeShape a sh:NodeShape ; sh:targetClass skos:ConceptScheme ; - sh:property [ - sh:path dct:title ; - sh:minCount 1; - sh:datatype rdf:langString ; - sh:message "Concept Scheme has no dct:title with a language tag!" ; - sh:severity sh:Violation ; - rdfs:comment "Tested with 01_cs_no_title.ttl" ; - ] ; + sh:or ( + [ + sh:path dct:title ; + sh:minCount 1; + sh:datatype rdf:langString ; + sh:message "Concept Scheme has no dct:title with a language tag!" ; + sh:severity sh:Violation ; + rdfs:comment "Tested with 01_cs_no_title.ttl" ; + ] + [ + sh:path skos:prefLabel ; + sh:minCount 1; + sh:datatype rdf:langString ; + sh:message "Concept Scheme has no skos:prefLabel with a language tag!" ; + sh:severity sh:Violation ; + rdfs:comment "Tested with 01_cs_no_title.ttl" ; + ] + [ + sh:path dc:title ; + sh:minCount 1; + sh:datatype rdf:langString ; + sh:message "Concept Scheme has no dc:title with a language tag!" ; + sh:severity sh:Violation ; + rdfs:comment "Tested with 01_cs_no_title.ttl" ; + ] + ); sh:property [ sh:path skos:hasTopConcept ; sh:minCount 1 ; @@ -40,15 +59,26 @@ sh:message "The target class for hasTopConcept should be skos:Concept" ; rdfs:comment "Tested with 03_cs_target_class_hasTopConcept.ttl" ; ] ; - sh:property [ - sh:path dct:description ; - sh:datatype rdf:langString ; - sh:severity sh:Warning ; - sh:minCount 1 ; - sh:message: "A description of the Concept Scheme should be provided." ; - rdfs:comment "Tested with 04_cs_no_description.ttl" ; - rdfs:comment "Tested with 05_cs_description_no_langstring.ttl" ; - ] ; + sh:or ( + [ + sh:path dct:description ; + sh:datatype rdf:langString ; + sh:severity sh:Warning ; + sh:minCount 1 ; + sh:message: "A description of the Concept Scheme should be provided." ; + rdfs:comment "Tested with 04_cs_no_description.ttl" ; + rdfs:comment "Tested with 05_cs_description_no_langstring.ttl" ; + ] + [ + sh:path dc:description ; + sh:datatype rdf:langString ; + sh:severity sh:Warning ; + sh:minCount 1 ; + sh:message: "A description of the Concept Scheme should be provided." ; + rdfs:comment "Tested with 04_cs_no_description.ttl" ; + rdfs:comment "Tested with 05_cs_description_no_langstring.ttl" ; + ] + ) ; sh:property [ sh:path dct:license ; sh:minCount 1 ;