shacl-engine
Version:
A fast RDF/JS SHACL engine
69 lines (67 loc) • 1.86 kB
text/turtle
#> .
#> .
#> .
#> .
#> .
#> .
#> .
#> .
#> .
ex:InvalidResource1
rdf:type rdfs:Resource ;
ex:property 42 ;
ex:property "Test Valid" ;
rdfs:label "Invalid resource1" ;
.
ex:TestShape
rdf:type sh:NodeShape ;
rdfs:label "Test shape" ;
sh:property ex:TestShape-property ;
sh:targetNode ex:InvalidResource1 ;
sh:targetNode ex:ValidResource1 ;
sh:targetNode ex:ValidResource2 ;
.
ex:TestShape-property
sh:path ex:property ;
sh:not [
sh:datatype xsd:integer ;
] ;
.
ex:ValidResource1
rdf:type rdfs:Resource ;
rdfs:label "Valid resource1" ;
.
ex:ValidResource2
rdf:type rdfs:Resource ;
ex:property 1.5 ;
ex:property "String" ;
rdfs:label "Valid resource2" ;
.
<>
rdf:type mf:Manifest ;
mf:entries (
<not-001>
) ;
.
<not-001>
rdf:type sht:Validate ;
rdfs:label "Test of sh:not at property shape 001" ;
mf:action [
sht:dataGraph <> ;
sht:shapesGraph <> ;
] ;
mf:result [
rdf:type sh:ValidationReport ;
sh:conforms "false"^^xsd:boolean ;
sh:result [
rdf:type sh:ValidationResult ;
sh:focusNode ex:InvalidResource1 ;
sh:resultPath ex:property ;
sh:resultSeverity sh:Violation ;
sh:sourceConstraintComponent sh:NotConstraintComponent ;
sh:sourceShape ex:TestShape-property ;
sh:value 42 ;
] ;
] ;
mf:status sht:approved ;
.