diff --git a/shacl12-test-suite/tests/core/complex/personexample.ttl b/shacl12-test-suite/tests/core/complex/personexample.ttl index 5794d7e8..ff52bcb7 100644 --- a/shacl12-test-suite/tests/core/complex/personexample.ttl +++ b/shacl12-test-suite/tests/core/complex/personexample.ttl @@ -1,105 +1,105 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Alice - rdf:type ex:Person ; - ex:ssn "987-65-432A" ; -. -ex:Bob - rdf:type ex:Person ; - ex:ssn "123-45-6789" ; - ex:ssn "124-35-6789" ; -. -ex:Calvin - rdf:type ex:Person ; - ex:birthDate "1999-09-09"^^xsd:date ; - ex:worksFor ex:UntypedCompany ; -. -ex:PersonShape - rdf:type sh:NodeShape ; - sh:closed "true"^^xsd:boolean ; - sh:ignoredProperties ( - rdf:type - ) ; - sh:property _:b61064 ; - sh:property _:b60054 ; - sh:property [ - sh:path [ - sh:inversePath ex:worksFor ; - ] ; - sh:name "employee" ; - ] ; - sh:targetClass ex:Person ; -. -_:b61064 - sh:path ex:ssn ; - sh:datatype xsd:string ; - sh:maxCount 1 ; - sh:pattern "^\\d{3}-\\d{2}-\\d{4}$" -. -_:b60054 - sh:path ex:worksFor ; - sh:class ex:Company ; - sh:nodeKind sh:IRI -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of personexample" ; - 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:Alice ; - sh:resultPath ex:ssn ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:PatternConstraintComponent ; - sh:sourceShape _:b61064 ; - sh:value "987-65-432A" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:Bob ; - sh:resultPath ex:ssn ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape _:b61064 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:Calvin ; - sh:resultPath ex:birthDate ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClosedConstraintComponent ; - sh:sourceShape ex:PersonShape ; - sh:value "1999-09-09"^^xsd:date ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:Calvin ; - sh:resultPath ex:worksFor ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape _:b60054 ; - sh:value ex:UntypedCompany ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Alice + rdf:type ex:Person ; + ex:ssn "987-65-432A" ; +. +ex:Bob + rdf:type ex:Person ; + ex:ssn "123-45-6789" ; + ex:ssn "124-35-6789" ; +. +ex:Calvin + rdf:type ex:Person ; + ex:birthDate "1999-09-09"^^xsd:date ; + ex:worksFor ex:UntypedCompany ; +. +ex:PersonShape + rdf:type sh:NodeShape ; + sh:closed "true"^^xsd:boolean ; + sh:ignoredProperties ( + rdf:type + ) ; + sh:property _:b61064 ; + sh:property _:b60054 ; + sh:property [ + sh:path [ + sh:inversePath ex:worksFor ; + ] ; + sh:name "employee" ; + ] ; + sh:targetClass ex:Person ; +. +_:b61064 + sh:path ex:ssn ; + sh:datatype xsd:string ; + sh:maxCount 1 ; + sh:pattern "^\\d{3}-\\d{2}-\\d{4}$" +. +_:b60054 + sh:path ex:worksFor ; + sh:class ex:Company ; + sh:nodeKind sh:IRI +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of personexample" ; + 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:Alice ; + sh:resultPath ex:ssn ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:PatternConstraintComponent ; + sh:sourceShape _:b61064 ; + sh:value "987-65-432A" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:Bob ; + sh:resultPath ex:ssn ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape _:b61064 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:Calvin ; + sh:resultPath ex:birthDate ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClosedConstraintComponent ; + sh:sourceShape ex:PersonShape ; + sh:value "1999-09-09"^^xsd:date ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:Calvin ; + sh:resultPath ex:worksFor ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape _:b60054 ; + sh:value ex:UntypedCompany ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/misc/deactivated-001.ttl b/shacl12-test-suite/tests/core/misc/deactivated-001.ttl index 809acde9..13db6e08 100644 --- a/shacl12-test-suite/tests/core/misc/deactivated-001.ttl +++ b/shacl12-test-suite/tests/core/misc/deactivated-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/misc/deactivated-002.ttl b/shacl12-test-suite/tests/core/misc/deactivated-002.ttl index 0498150f..9f841ead 100644 --- a/shacl12-test-suite/tests/core/misc/deactivated-002.ttl +++ b/shacl12-test-suite/tests/core/misc/deactivated-002.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/misc/message-001.ttl b/shacl12-test-suite/tests/core/misc/message-001.ttl index 2d3fb135..132295bc 100644 --- a/shacl12-test-suite/tests/core/misc/message-001.ttl +++ b/shacl12-test-suite/tests/core/misc/message-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/misc/severity-001.ttl b/shacl12-test-suite/tests/core/misc/severity-001.ttl index 5b3e6b8c..ad568b1c 100644 --- a/shacl12-test-suite/tests/core/misc/severity-001.ttl +++ b/shacl12-test-suite/tests/core/misc/severity-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/misc/severity-002.ttl b/shacl12-test-suite/tests/core/misc/severity-002.ttl index 87b2aed7..5e7d071d 100644 --- a/shacl12-test-suite/tests/core/misc/severity-002.ttl +++ b/shacl12-test-suite/tests/core/misc/severity-002.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/node/and-001.ttl b/shacl12-test-suite/tests/core/node/and-001.ttl index d0d86768..626a47c9 100644 --- a/shacl12-test-suite/tests/core/node/and-001.ttl +++ b/shacl12-test-suite/tests/core/node/and-001.ttl @@ -1,77 +1,77 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidRectangle1 - rdf:type ex:Rectangle ; - ex:height 3 ; -. -ex:InvalidRectangle2 - rdf:type ex:Rectangle ; - ex:width 2 ; -. -ex:Rectangle - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:subClassOf rdfs:Resource ; - sh:and ( - [ - sh:property [ - sh:path ex:width ; - sh:minCount 1 ; - ] ; - ] - [ - sh:property [ - sh:path ex:height ; - sh:minCount 1 ; - ] ; - ] - ) ; -. -ex:ValidRectangle1 - rdf:type ex:Rectangle ; - ex:height 3 ; - ex:width 2 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:and at node 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:InvalidRectangle1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:AndConstraintComponent ; - sh:sourceShape ex:Rectangle ; - sh:value ex:InvalidRectangle1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidRectangle2 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:AndConstraintComponent ; - sh:sourceShape ex:Rectangle ; - sh:value ex:InvalidRectangle2 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidRectangle1 + rdf:type ex:Rectangle ; + ex:height 3 ; +. +ex:InvalidRectangle2 + rdf:type ex:Rectangle ; + ex:width 2 ; +. +ex:Rectangle + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:subClassOf rdfs:Resource ; + sh:and ( + [ + sh:property [ + sh:path ex:width ; + sh:minCount 1 ; + ] ; + ] + [ + sh:property [ + sh:path ex:height ; + sh:minCount 1 ; + ] ; + ] + ) ; +. +ex:ValidRectangle1 + rdf:type ex:Rectangle ; + ex:height 3 ; + ex:width 2 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:and at node 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:InvalidRectangle1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:AndConstraintComponent ; + sh:sourceShape ex:Rectangle ; + sh:value ex:InvalidRectangle1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidRectangle2 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:AndConstraintComponent ; + sh:sourceShape ex:Rectangle ; + sh:value ex:InvalidRectangle2 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/and-002.ttl b/shacl12-test-suite/tests/core/node/and-002.ttl index f4b018db..f624e327 100644 --- a/shacl12-test-suite/tests/core/node/and-002.ttl +++ b/shacl12-test-suite/tests/core/node/and-002.ttl @@ -1,74 +1,74 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:AndShape - rdf:type sh:NodeShape ; - sh:and ( - ex:SuperShape - [ - sh:property [ - sh:path ex:property ; - sh:maxCount 1 ; - ] ; - ] - ) ; - sh:targetNode ex:InvalidInstance1 ; - sh:targetNode ex:InvalidInstance2 ; - sh:targetNode ex:ValidInstance1 ; -. -ex:InvalidInstance2 - ex:property "One" ; - ex:property "Two" ; -. -ex:SuperShape - rdf:type sh:NodeShape ; - sh:property [ - sh:path ex:property ; - sh:minCount 1 ; - ] ; -. -ex:ValidInstance1 - ex:property "One" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:and at node shape 002" ; - 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:InvalidInstance1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:AndConstraintComponent ; - sh:sourceShape ex:AndShape ; - sh:value ex:InvalidInstance1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance2 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:AndConstraintComponent ; - sh:sourceShape ex:AndShape ; - sh:value ex:InvalidInstance2 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:AndShape + rdf:type sh:NodeShape ; + sh:and ( + ex:SuperShape + [ + sh:property [ + sh:path ex:property ; + sh:maxCount 1 ; + ] ; + ] + ) ; + sh:targetNode ex:InvalidInstance1 ; + sh:targetNode ex:InvalidInstance2 ; + sh:targetNode ex:ValidInstance1 ; +. +ex:InvalidInstance2 + ex:property "One" ; + ex:property "Two" ; +. +ex:SuperShape + rdf:type sh:NodeShape ; + sh:property [ + sh:path ex:property ; + sh:minCount 1 ; + ] ; +. +ex:ValidInstance1 + ex:property "One" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:and at node shape 002" ; + 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:InvalidInstance1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:AndConstraintComponent ; + sh:sourceShape ex:AndShape ; + sh:value ex:InvalidInstance1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance2 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:AndConstraintComponent ; + sh:sourceShape ex:AndShape ; + sh:value ex:InvalidInstance2 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/class-001.ttl b/shacl12-test-suite/tests/core/node/class-001.ttl index ab979774..784ca125 100644 --- a/shacl12-test-suite/tests/core/node/class-001.ttl +++ b/shacl12-test-suite/tests/core/node/class-001.ttl @@ -1,70 +1,70 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:John - rdf:type ex:MalePerson ; -. -ex:MalePerson - rdf:type rdfs:Class ; - rdfs:subClassOf ex:Person ; -. -ex:Person - rdf:type rdfs:Class ; - rdfs:subClassOf rdfs:Resource ; -. -ex:Quokki - rdf:type ex:Animal ; -. -ex:Someone - rdf:type ex:Person ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:class ex:Person ; - sh:targetNode ex:John ; - sh:targetNode ex:Quokki ; - sh:targetNode ex:Someone ; - sh:targetNode ex:Typeless ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:class at node 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:Quokki ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:Quokki ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:Typeless ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:Typeless ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:John + rdf:type ex:MalePerson ; +. +ex:MalePerson + rdf:type rdfs:Class ; + rdfs:subClassOf ex:Person ; +. +ex:Person + rdf:type rdfs:Class ; + rdfs:subClassOf rdfs:Resource ; +. +ex:Quokki + rdf:type ex:Animal ; +. +ex:Someone + rdf:type ex:Person ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:class ex:Person ; + sh:targetNode ex:John ; + sh:targetNode ex:Quokki ; + sh:targetNode ex:Someone ; + sh:targetNode ex:Typeless ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:class at node 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:Quokki ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:Quokki ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:Typeless ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:Typeless ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/class-002.ttl b/shacl12-test-suite/tests/core/node/class-002.ttl index 71ed5e0d..d821ff6c 100644 --- a/shacl12-test-suite/tests/core/node/class-002.ttl +++ b/shacl12-test-suite/tests/core/node/class-002.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/node/class-003.ttl b/shacl12-test-suite/tests/core/node/class-003.ttl index 16b37be4..66c1927a 100644 --- a/shacl12-test-suite/tests/core/node/class-003.ttl +++ b/shacl12-test-suite/tests/core/node/class-003.ttl @@ -1,105 +1,105 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:John # not Animal - rdf:type ex:MalePerson ; -. -ex:Joe # OK - rdf:type ex:MalePerson ; - rdf:type ex:Animal ; -. -ex:MalePerson - rdf:type rdfs:Class ; - rdfs:subClassOf ex:Person ; -. -ex:Person - rdf:type rdfs:Class ; - rdfs:subClassOf rdfs:Resource ; -. -ex:Quokki # not Person - rdf:type ex:Animal ; -. -ex:Quokkip # not Animal - rdf:type ex:Person ; -. -ex:Someone # OK - rdf:type ex:Person ; - rdf:type ex:Animal ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:class ex:Person ; - sh:class ex:Animal ; - sh:targetClass ex:MalePerson ; - sh:targetNode ex:John ; - sh:targetNode ex:Quokki ; - sh:targetNode ex:Quokkip ; - sh:targetNode ex:Someone ; - sh:targetNode ex:Typeless ; # not Animal, not Person -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:class at node shape 003 multiple classes, overlapping target sets" ; - 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:Typeless ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:Typeless ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:Typeless ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:Typeless ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:Quokki ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:Quokki ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:John ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:John ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:Quokkip ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:Quokkip ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:John # not Animal + rdf:type ex:MalePerson ; +. +ex:Joe # OK + rdf:type ex:MalePerson ; + rdf:type ex:Animal ; +. +ex:MalePerson + rdf:type rdfs:Class ; + rdfs:subClassOf ex:Person ; +. +ex:Person + rdf:type rdfs:Class ; + rdfs:subClassOf rdfs:Resource ; +. +ex:Quokki # not Person + rdf:type ex:Animal ; +. +ex:Quokkip # not Animal + rdf:type ex:Person ; +. +ex:Someone # OK + rdf:type ex:Person ; + rdf:type ex:Animal ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:class ex:Person ; + sh:class ex:Animal ; + sh:targetClass ex:MalePerson ; + sh:targetNode ex:John ; + sh:targetNode ex:Quokki ; + sh:targetNode ex:Quokkip ; + sh:targetNode ex:Someone ; + sh:targetNode ex:Typeless ; # not Animal, not Person +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:class at node shape 003 multiple classes, overlapping target sets" ; + 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:Typeless ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:Typeless ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:Typeless ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:Typeless ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:Quokki ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:Quokki ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:John ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:John ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:Quokkip ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:Quokkip ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/closed-001.ttl b/shacl12-test-suite/tests/core/node/closed-001.ttl index 6bae9de8..8d8e60c0 100644 --- a/shacl12-test-suite/tests/core/node/closed-001.ttl +++ b/shacl12-test-suite/tests/core/node/closed-001.ttl @@ -1,64 +1,64 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:SomeClass ; - ex:otherProperty 4 ; - ex:someProperty 3 ; -. -ex:MyShape - rdf:type sh:NodeShape ; - sh:closed "true"^^xsd:boolean ; - sh:property [ - sh:path ex:someProperty ; - ] ; - sh:targetNode ex:InvalidInstance1 ; - sh:targetNode ex:ValidInstance1 ; -. -ex:ValidInstance1 - ex:someProperty 3 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:closed at node 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:InvalidInstance1 ; - sh:resultPath rdf:type ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClosedConstraintComponent ; - sh:sourceShape ex:MyShape ; - sh:value ex:SomeClass ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance1 ; - sh:resultPath ex:otherProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClosedConstraintComponent ; - sh:sourceShape ex:MyShape ; - sh:value 4 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:SomeClass ; + ex:otherProperty 4 ; + ex:someProperty 3 ; +. +ex:MyShape + rdf:type sh:NodeShape ; + sh:closed "true"^^xsd:boolean ; + sh:property [ + sh:path ex:someProperty ; + ] ; + sh:targetNode ex:InvalidInstance1 ; + sh:targetNode ex:ValidInstance1 ; +. +ex:ValidInstance1 + ex:someProperty 3 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:closed at node 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:InvalidInstance1 ; + sh:resultPath rdf:type ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClosedConstraintComponent ; + sh:sourceShape ex:MyShape ; + sh:value ex:SomeClass ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance1 ; + sh:resultPath ex:otherProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClosedConstraintComponent ; + sh:sourceShape ex:MyShape ; + sh:value 4 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/closed-002.ttl b/shacl12-test-suite/tests/core/node/closed-002.ttl index d72eebb4..ba32f81d 100644 --- a/shacl12-test-suite/tests/core/node/closed-002.ttl +++ b/shacl12-test-suite/tests/core/node/closed-002.ttl @@ -1,58 +1,58 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - ex:otherProperty 4 ; - ex:someProperty 3 ; -. -ex:MyShape - rdf:type sh:NodeShape ; - sh:closed "true"^^xsd:boolean ; - sh:ignoredProperties ( - rdf:type - ) ; - sh:property [ - sh:path ex:someProperty ; - ] ; - sh:targetNode ex:InvalidInstance1 ; - sh:targetNode ex:ValidInstance1 ; -. -ex:ValidInstance1 - rdf:type ex:SomeClass ; - ex:someProperty 3 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:closed at node shape 002" ; - 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:InvalidInstance1 ; - sh:resultPath ex:otherProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClosedConstraintComponent ; - sh:sourceShape ex:MyShape ; - sh:value 4 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + ex:otherProperty 4 ; + ex:someProperty 3 ; +. +ex:MyShape + rdf:type sh:NodeShape ; + sh:closed "true"^^xsd:boolean ; + sh:ignoredProperties ( + rdf:type + ) ; + sh:property [ + sh:path ex:someProperty ; + ] ; + sh:targetNode ex:InvalidInstance1 ; + sh:targetNode ex:ValidInstance1 ; +. +ex:ValidInstance1 + rdf:type ex:SomeClass ; + ex:someProperty 3 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:closed at node shape 002" ; + 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:InvalidInstance1 ; + sh:resultPath ex:otherProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClosedConstraintComponent ; + sh:sourceShape ex:MyShape ; + sh:value 4 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/datatype-001.ttl b/shacl12-test-suite/tests/core/node/datatype-001.ttl index 427572d4..401f6e4b 100644 --- a/shacl12-test-suite/tests/core/node/datatype-001.ttl +++ b/shacl12-test-suite/tests/core/node/datatype-001.ttl @@ -1,64 +1,64 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:datatype xsd:integer ; - sh:targetClass ex:TestClass ; - sh:targetNode xsd:integer ; - sh:targetNode 42 ; - sh:targetNode "aldi"^^xsd:integer ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:datatype at node 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 xsd:integer ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value xsd:integer ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "aldi"^^xsd:integer ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "aldi"^^xsd:integer ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode _:b30507 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value _:b30507 ; - ] ; - ] ; - mf:status sht:approved ; -. -_:b30507 - rdf:type ex:TestClass ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:datatype xsd:integer ; + sh:targetClass ex:TestClass ; + sh:targetNode xsd:integer ; + sh:targetNode 42 ; + sh:targetNode "aldi"^^xsd:integer ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:datatype at node 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 xsd:integer ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value xsd:integer ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "aldi"^^xsd:integer ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "aldi"^^xsd:integer ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode _:b30507 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value _:b30507 ; + ] ; + ] ; + mf:status sht:approved ; +. +_:b30507 + rdf:type ex:TestClass ; +. diff --git a/shacl12-test-suite/tests/core/node/datatype-002.ttl b/shacl12-test-suite/tests/core/node/datatype-002.ttl index 6e9e0121..d40b367e 100644 --- a/shacl12-test-suite/tests/core/node/datatype-002.ttl +++ b/shacl12-test-suite/tests/core/node/datatype-002.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/node/disjoint-001.ttl b/shacl12-test-suite/tests/core/node/disjoint-001.ttl index d98158ad..1bc0e048 100644 --- a/shacl12-test-suite/tests/core/node/disjoint-001.ttl +++ b/shacl12-test-suite/tests/core/node/disjoint-001.ttl @@ -1,51 +1,51 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:property ex:InvalidResource1 ; - ex:property ex:ValidResource1 ; -. -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:disjoint ex:property ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:ValidResource1 ; -. -ex:ValidResource1 - ex:property ex:InvalidResource1 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:disjoint at node 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:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DisjointConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource1 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:property ex:InvalidResource1 ; + ex:property ex:ValidResource1 ; +. +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:disjoint ex:property ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:ValidResource1 ; +. +ex:ValidResource1 + ex:property ex:InvalidResource1 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:disjoint at node 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:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DisjointConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource1 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/equals-001.ttl b/shacl12-test-suite/tests/core/node/equals-001.ttl index 8f23966b..011d5d08 100644 --- a/shacl12-test-suite/tests/core/node/equals-001.ttl +++ b/shacl12-test-suite/tests/core/node/equals-001.ttl @@ -1,59 +1,59 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:property ex:InvalidResource1 ; - ex:property ex:SomeValue ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:equals ex:property ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:InvalidResource2 ; - sh:targetNode ex:ValidResource1 ; -. -ex:ValidResource1 - ex:property ex:ValidResource1 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:equals at node 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:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:EqualsConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:SomeValue ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:EqualsConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource2 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:property ex:InvalidResource1 ; + ex:property ex:SomeValue ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:equals ex:property ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:InvalidResource2 ; + sh:targetNode ex:ValidResource1 ; +. +ex:ValidResource1 + ex:property ex:ValidResource1 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:equals at node 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:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:EqualsConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:SomeValue ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:EqualsConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource2 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/hasValue-001.ttl b/shacl12-test-suite/tests/core/node/hasValue-001.ttl index 0a9945af..6760b893 100644 --- a/shacl12-test-suite/tests/core/node/hasValue-001.ttl +++ b/shacl12-test-suite/tests/core/node/hasValue-001.ttl @@ -1,44 +1,44 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:hasValue "Test" ; - sh:targetNode "Invalid String" ; - sh:targetNode "Test" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:hasValue at node 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 "Invalid String" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:HasValueConstraintComponent ; - sh:sourceShape ex:TestShape ; - # See See https://github.com/w3c/data-shapes/issues/111: don't create sh:value "Invalid String" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:hasValue "Test" ; + sh:targetNode "Invalid String" ; + sh:targetNode "Test" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:hasValue at node 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 "Invalid String" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:HasValueConstraintComponent ; + sh:sourceShape ex:TestShape ; + # See See https://github.com/w3c/data-shapes/issues/111: don't create sh:value "Invalid String" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/in-001.ttl b/shacl12-test-suite/tests/core/node/in-001.ttl index 8fb4c085..e481c2b5 100644 --- a/shacl12-test-suite/tests/core/node/in-001.ttl +++ b/shacl12-test-suite/tests/core/node/in-001.ttl @@ -1,63 +1,63 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Green - rdf:type ex:TestShape ; - rdfs:label "Green" ; -. -ex:InvalidInstance - rdf:type ex:TestShape ; - rdfs:label "Invalid instance" ; -. -ex:Red - rdf:type ex:TestShape ; - rdfs:label "Red" ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:in ( - ex:Green - ex:Red - ex:Yellow - ) ; -. -ex:Yellow - rdf:type ex:TestShape ; - rdfs:label "Yellow" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:in at node 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:InvalidInstance ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:InConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidInstance ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Green + rdf:type ex:TestShape ; + rdfs:label "Green" ; +. +ex:InvalidInstance + rdf:type ex:TestShape ; + rdfs:label "Invalid instance" ; +. +ex:Red + rdf:type ex:TestShape ; + rdfs:label "Red" ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:in ( + ex:Green + ex:Red + ex:Yellow + ) ; +. +ex:Yellow + rdf:type ex:TestShape ; + rdfs:label "Yellow" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:in at node 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:InvalidInstance ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:InConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidInstance ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/languageIn-001.ttl b/shacl12-test-suite/tests/core/node/languageIn-001.ttl index b8365d25..e905a51b 100644 --- a/shacl12-test-suite/tests/core/node/languageIn-001.ttl +++ b/shacl12-test-suite/tests/core/node/languageIn-001.ttl @@ -1,66 +1,66 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:languageIn ( - "en" - "fr" - ) ; - sh:targetNode rdfs:Resource ; - sh:targetNode "Deutsch"@de ; - sh:targetNode "English"@en ; - sh:targetNode "Francais"@fr ; - sh:targetNode "Plain String" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:languageIn at node 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 rdfs:Resource ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value rdfs:Resource ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "Deutsch"@de ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Deutsch"@de ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "Plain String" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Plain String" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:languageIn ( + "en" + "fr" + ) ; + sh:targetNode rdfs:Resource ; + sh:targetNode "Deutsch"@de ; + sh:targetNode "English"@en ; + sh:targetNode "Francais"@fr ; + sh:targetNode "Plain String" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:languageIn at node 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 rdfs:Resource ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value rdfs:Resource ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "Deutsch"@de ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Deutsch"@de ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "Plain String" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Plain String" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/maxExclusive-001.ttl b/shacl12-test-suite/tests/core/node/maxExclusive-001.ttl index 7c2b1771..07a87a92 100644 --- a/shacl12-test-suite/tests/core/node/maxExclusive-001.ttl +++ b/shacl12-test-suite/tests/core/node/maxExclusive-001.ttl @@ -1,91 +1,91 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:maxExclusive 4 ; - sh:targetClass ex:TestClass ; - sh:targetNode ex:John ; - sh:targetNode 3.9 ; - sh:targetNode 4 ; - sh:targetNode 4.0 ; - sh:targetNode 4.1 ; - sh:targetNode "Hello" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:maxExclusive at node 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:John ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:John ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 4 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 4 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 4.0 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 4.0 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 4.1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 4.1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "Hello" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Hello" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode _:b11982 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value _:b11982 ; - ] ; - ] ; - mf:status sht:approved ; -. -_:b11982 - rdf:type ex:TestClass ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:maxExclusive 4 ; + sh:targetClass ex:TestClass ; + sh:targetNode ex:John ; + sh:targetNode 3.9 ; + sh:targetNode 4 ; + sh:targetNode 4.0 ; + sh:targetNode 4.1 ; + sh:targetNode "Hello" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:maxExclusive at node 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:John ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:John ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 4 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 4 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 4.0 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 4.0 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 4.1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 4.1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "Hello" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Hello" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode _:b11982 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value _:b11982 ; + ] ; + ] ; + mf:status sht:approved ; +. +_:b11982 + rdf:type ex:TestClass ; +. diff --git a/shacl12-test-suite/tests/core/node/maxInclusive-001.ttl b/shacl12-test-suite/tests/core/node/maxInclusive-001.ttl index f30c9425..ddfe6c59 100644 --- a/shacl12-test-suite/tests/core/node/maxInclusive-001.ttl +++ b/shacl12-test-suite/tests/core/node/maxInclusive-001.ttl @@ -1,75 +1,75 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:maxInclusive 4 ; - sh:targetClass ex:TestClass ; - sh:targetNode ex:John ; - sh:targetNode 3.9 ; - sh:targetNode 4 ; - sh:targetNode 4.0 ; - sh:targetNode 4.1 ; - sh:targetNode "Hello" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:maxInclusive at node 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:John ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:John ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 4.1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 4.1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "Hello" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Hello" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode _:b22005 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value _:b22005 ; - ] ; - ] ; - mf:status sht:approved ; -. -_:b22005 - rdf:type ex:TestClass ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:maxInclusive 4 ; + sh:targetClass ex:TestClass ; + sh:targetNode ex:John ; + sh:targetNode 3.9 ; + sh:targetNode 4 ; + sh:targetNode 4.0 ; + sh:targetNode 4.1 ; + sh:targetNode "Hello" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:maxInclusive at node 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:John ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:John ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 4.1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 4.1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "Hello" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Hello" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode _:b22005 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value _:b22005 ; + ] ; + ] ; + mf:status sht:approved ; +. +_:b22005 + rdf:type ex:TestClass ; +. diff --git a/shacl12-test-suite/tests/core/node/maxLength-001.ttl b/shacl12-test-suite/tests/core/node/maxLength-001.ttl index bd197e25..07542054 100644 --- a/shacl12-test-suite/tests/core/node/maxLength-001.ttl +++ b/shacl12-test-suite/tests/core/node/maxLength-001.ttl @@ -1,87 +1,87 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:maxLength 4 ; - sh:targetClass ex:TestClass ; - sh:targetNode ; - sh:targetNode ex:John ; - sh:targetNode 123 ; - sh:targetNode 1234 ; - sh:targetNode 12345 ; - sh:targetNode "2017-03-29"^^xsd:date ; - sh:targetNode "Hel" ; - sh:targetNode "Hell" ; - sh:targetNode "Hell"@en ; - sh:targetNode "Hello" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:maxLength at node 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:John ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:John ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 12345 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 12345 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "2017-03-29"^^xsd:date ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "2017-03-29"^^xsd:date ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "Hello" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Hello" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode _:b34236 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value _:b34236 ; - ] ; - ] ; - mf:status sht:approved ; -. -_:b34236 - rdf:type ex:TestClass ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:maxLength 4 ; + sh:targetClass ex:TestClass ; + sh:targetNode ; + sh:targetNode ex:John ; + sh:targetNode 123 ; + sh:targetNode 1234 ; + sh:targetNode 12345 ; + sh:targetNode "2017-03-29"^^xsd:date ; + sh:targetNode "Hel" ; + sh:targetNode "Hell" ; + sh:targetNode "Hell"@en ; + sh:targetNode "Hello" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:maxLength at node 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:John ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:John ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 12345 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 12345 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "2017-03-29"^^xsd:date ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "2017-03-29"^^xsd:date ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "Hello" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Hello" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode _:b34236 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value _:b34236 ; + ] ; + ] ; + mf:status sht:approved ; +. +_:b34236 + rdf:type ex:TestClass ; +. diff --git a/shacl12-test-suite/tests/core/node/minExclusive-001.ttl b/shacl12-test-suite/tests/core/node/minExclusive-001.ttl index 72191504..5414c63b 100644 --- a/shacl12-test-suite/tests/core/node/minExclusive-001.ttl +++ b/shacl12-test-suite/tests/core/node/minExclusive-001.ttl @@ -1,91 +1,91 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:minExclusive 4 ; - sh:targetClass ex:TestClass ; - sh:targetNode ex:John ; - sh:targetNode 3.9 ; - sh:targetNode 4 ; - sh:targetNode 4.0 ; - sh:targetNode 4.1 ; - sh:targetNode "Hello" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minExclusive at node 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:John ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:John ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 3.9 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 3.9 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 4 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 4 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 4.0 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 4.0 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "Hello" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Hello" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode _:b33079 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value _:b33079 ; - ] ; - ] ; - mf:status sht:approved ; -. -_:b33079 - rdf:type ex:TestClass ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:minExclusive 4 ; + sh:targetClass ex:TestClass ; + sh:targetNode ex:John ; + sh:targetNode 3.9 ; + sh:targetNode 4 ; + sh:targetNode 4.0 ; + sh:targetNode 4.1 ; + sh:targetNode "Hello" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minExclusive at node 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:John ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:John ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 3.9 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 3.9 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 4 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 4 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 4.0 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 4.0 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "Hello" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Hello" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode _:b33079 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value _:b33079 ; + ] ; + ] ; + mf:status sht:approved ; +. +_:b33079 + rdf:type ex:TestClass ; +. diff --git a/shacl12-test-suite/tests/core/node/minInclusive-001.ttl b/shacl12-test-suite/tests/core/node/minInclusive-001.ttl index e2113bf0..e3e5e583 100644 --- a/shacl12-test-suite/tests/core/node/minInclusive-001.ttl +++ b/shacl12-test-suite/tests/core/node/minInclusive-001.ttl @@ -1,44 +1,44 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:minInclusive 8 ; - sh:targetNode 7 ; - sh:targetNode 8 ; - sh:targetNode 9 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minInclusive at node 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 7 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 7 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:minInclusive 8 ; + sh:targetNode 7 ; + sh:targetNode 8 ; + sh:targetNode 9 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minInclusive at node 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 7 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 7 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/minInclusive-002.ttl b/shacl12-test-suite/tests/core/node/minInclusive-002.ttl index e9a8d5ee..2cf16318 100644 --- a/shacl12-test-suite/tests/core/node/minInclusive-002.ttl +++ b/shacl12-test-suite/tests/core/node/minInclusive-002.ttl @@ -1,61 +1,61 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape a sh:NodeShape ; - sh:minInclusive "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; - sh:targetNode "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; - sh:targetNode "2002-10-10T12:00:01-05:00"^^xsd:dateTime ; - sh:targetNode "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; - sh:targetNode "2002-10-10T12:00:00"^^xsd:dateTime ; - sh:targetNode ex:TestShape ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minInclusive at node shape 002 - dateTime with timezone" ; - 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 "2002-10-10T12:00:00"^^xsd:dateTime ; - sh:value "2002-10-10T12:00:00"^^xsd:dateTime ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; - sh:value "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:TestShape ; - sh:value ex:TestShape ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape a sh:NodeShape ; + sh:minInclusive "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; + sh:targetNode "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; + sh:targetNode "2002-10-10T12:00:01-05:00"^^xsd:dateTime ; + sh:targetNode "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; + sh:targetNode "2002-10-10T12:00:00"^^xsd:dateTime ; + sh:targetNode ex:TestShape ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minInclusive at node shape 002 - dateTime with timezone" ; + 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 "2002-10-10T12:00:00"^^xsd:dateTime ; + sh:value "2002-10-10T12:00:00"^^xsd:dateTime ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; + sh:value "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:TestShape ; + sh:value ex:TestShape ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/minInclusive-003.ttl b/shacl12-test-suite/tests/core/node/minInclusive-003.ttl index 306ca78b..5207be93 100644 --- a/shacl12-test-suite/tests/core/node/minInclusive-003.ttl +++ b/shacl12-test-suite/tests/core/node/minInclusive-003.ttl @@ -1,70 +1,70 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:minInclusive "2002-10-10T12:00:00"^^xsd:dateTime ; - sh:targetNode "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; - sh:targetNode "2002-10-10T12:00:01-05:00"^^xsd:dateTime ; - sh:targetNode "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; - sh:targetNode "2002-10-10T12:00:00"^^xsd:dateTime ; - sh:targetNode ex:TestShape ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minInclusive at node shape 003 - dateTime without timezone" ; - 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 "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "2002-10-10T12:00:01-05:00"^^xsd:dateTime ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "2002-10-10T12:00:01-05:00"^^xsd:dateTime ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:TestShape ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:TestShape ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:minInclusive "2002-10-10T12:00:00"^^xsd:dateTime ; + sh:targetNode "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; + sh:targetNode "2002-10-10T12:00:01-05:00"^^xsd:dateTime ; + sh:targetNode "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; + sh:targetNode "2002-10-10T12:00:00"^^xsd:dateTime ; + sh:targetNode ex:TestShape ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minInclusive at node shape 003 - dateTime without timezone" ; + 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 "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "2002-10-10T12:00:00-05:00"^^xsd:dateTime ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "2002-10-10T12:00:01-05:00"^^xsd:dateTime ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "2002-10-10T12:00:01-05:00"^^xsd:dateTime ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "2002-10-09T12:00:00-05:00"^^xsd:dateTime ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:TestShape ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:TestShape ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/minLength-001.ttl b/shacl12-test-suite/tests/core/node/minLength-001.ttl index 75151fe7..8a568576 100644 --- a/shacl12-test-suite/tests/core/node/minLength-001.ttl +++ b/shacl12-test-suite/tests/core/node/minLength-001.ttl @@ -1,79 +1,79 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:minLength 4 ; - sh:targetClass ex:TestClass ; - sh:targetNode ; - sh:targetNode ex:John ; - sh:targetNode 123 ; - sh:targetNode 1234 ; - sh:targetNode 12345 ; - sh:targetNode "2017-03-29"^^xsd:date ; - sh:targetNode "Hel" ; - sh:targetNode "Hell" ; - sh:targetNode "Hell"@en ; - sh:targetNode "Hello" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minLength at node 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 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 123 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 123 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "Hel" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Hel" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode _:b19019 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value _:b19019 ; - ] ; - ] ; - mf:status sht:approved ; -. -_:b19019 - rdf:type ex:TestClass ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:minLength 4 ; + sh:targetClass ex:TestClass ; + sh:targetNode ; + sh:targetNode ex:John ; + sh:targetNode 123 ; + sh:targetNode 1234 ; + sh:targetNode 12345 ; + sh:targetNode "2017-03-29"^^xsd:date ; + sh:targetNode "Hel" ; + sh:targetNode "Hell" ; + sh:targetNode "Hell"@en ; + sh:targetNode "Hello" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minLength at node 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 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 123 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 123 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "Hel" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Hel" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode _:b19019 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value _:b19019 ; + ] ; + ] ; + mf:status sht:approved ; +. +_:b19019 + rdf:type ex:TestClass ; +. diff --git a/shacl12-test-suite/tests/core/node/node-001.ttl b/shacl12-test-suite/tests/core/node/node-001.ttl index b6d71708..f1e7d458 100644 --- a/shacl12-test-suite/tests/core/node/node-001.ttl +++ b/shacl12-test-suite/tests/core/node/node-001.ttl @@ -1,55 +1,55 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance - rdf:type ex:TestClass ; - rdfs:label "Invalid instance" ; -. -ex:TestClass - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test class" ; - rdfs:subClassOf rdfs:Resource ; - sh:node [ - sh:class ex:OtherClass ; - ] ; -. -ex:ValidInstance - rdf:type ex:OtherClass ; - rdf:type ex:TestClass ; - rdfs:label "Valid instance" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:node at node 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:InvalidInstance ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeConstraintComponent ; - sh:sourceShape ex:TestClass ; - sh:value ex:InvalidInstance ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance + rdf:type ex:TestClass ; + rdfs:label "Invalid instance" ; +. +ex:TestClass + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test class" ; + rdfs:subClassOf rdfs:Resource ; + sh:node [ + sh:class ex:OtherClass ; + ] ; +. +ex:ValidInstance + rdf:type ex:OtherClass ; + rdf:type ex:TestClass ; + rdfs:label "Valid instance" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:node at node 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:InvalidInstance ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeConstraintComponent ; + sh:sourceShape ex:TestClass ; + sh:value ex:InvalidInstance ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/nodeKind-001.ttl b/shacl12-test-suite/tests/core/node/nodeKind-001.ttl index 004f8fa2..be7dbeb6 100644 --- a/shacl12-test-suite/tests/core/node/nodeKind-001.ttl +++ b/shacl12-test-suite/tests/core/node/nodeKind-001.ttl @@ -1,43 +1,43 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:IRITestShape - rdf:type sh:NodeShape ; - sh:nodeKind sh:IRI ; - sh:targetNode ex:John ; - sh:targetNode "true"^^xsd:boolean ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:nodeKind at node 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 "true"^^xsd:boolean ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape ex:IRITestShape ; - sh:value "true"^^xsd:boolean ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:IRITestShape + rdf:type sh:NodeShape ; + sh:nodeKind sh:IRI ; + sh:targetNode ex:John ; + sh:targetNode "true"^^xsd:boolean ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:nodeKind at node 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 "true"^^xsd:boolean ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape ex:IRITestShape ; + sh:value "true"^^xsd:boolean ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/not-001.ttl b/shacl12-test-suite/tests/core/node/not-001.ttl index 588436cf..d21ebaa8 100644 --- a/shacl12-test-suite/tests/core/node/not-001.ttl +++ b/shacl12-test-suite/tests/core/node/not-001.ttl @@ -1,59 +1,59 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - rdf:type rdfs:Resource ; - ex:property "some value" ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - rdfs:subClassOf rdfs:Resource ; - sh:not [ - rdf:type sh:NodeShape ; - sh:property [ - sh:path ex:property ; - sh:minCount 1 ; - ] ; - ] ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:ValidResource1 ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:not at node 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:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NotConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource1 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + rdf:type rdfs:Resource ; + ex:property "some value" ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + rdfs:subClassOf rdfs:Resource ; + sh:not [ + rdf:type sh:NodeShape ; + sh:property [ + sh:path ex:property ; + sh:minCount 1 ; + ] ; + ] ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:ValidResource1 ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:not at node 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:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NotConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource1 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/not-002.ttl b/shacl12-test-suite/tests/core/node/not-002.ttl index cf43632d..674e7b5d 100644 --- a/shacl12-test-suite/tests/core/node/not-002.ttl +++ b/shacl12-test-suite/tests/core/node/not-002.ttl @@ -1,52 +1,52 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - ex:property "Some value" ; -. -ex:NotExampleShape - rdf:type sh:NodeShape ; - sh:not [ - rdf:type sh:NodeShape ; - sh:property [ - sh:path ex:property ; - sh:minCount 1 ; - ] ; - ] ; - sh:targetNode ex:InvalidInstance1 ; - sh:targetNode ex:ValidInstance1 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:not at node shape 002" ; - 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:InvalidInstance1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NotConstraintComponent ; - sh:sourceShape ex:NotExampleShape ; - sh:value ex:InvalidInstance1 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + ex:property "Some value" ; +. +ex:NotExampleShape + rdf:type sh:NodeShape ; + sh:not [ + rdf:type sh:NodeShape ; + sh:property [ + sh:path ex:property ; + sh:minCount 1 ; + ] ; + ] ; + sh:targetNode ex:InvalidInstance1 ; + sh:targetNode ex:ValidInstance1 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:not at node shape 002" ; + 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:InvalidInstance1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NotConstraintComponent ; + sh:sourceShape ex:NotExampleShape ; + sh:value ex:InvalidInstance1 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/or-001.ttl b/shacl12-test-suite/tests/core/node/or-001.ttl index 455c8c64..c7ff4088 100644 --- a/shacl12-test-suite/tests/core/node/or-001.ttl +++ b/shacl12-test-suite/tests/core/node/or-001.ttl @@ -1,91 +1,91 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidRectangle1 - rdf:type ex:RectangleWithArea ; - ex:height 3 ; -. -ex:InvalidRectangle2 - rdf:type ex:RectangleWithArea ; -. -ex:RectangleWithArea - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:subClassOf rdfs:Resource ; - sh:or ( - [ - sh:property [ - sh:path ex:height ; - sh:minCount 1 ; - ] ; - sh:property [ - sh:path ex:width ; - sh:minCount 1 ; - ] ; - ] - [ - sh:property [ - sh:path ex:area ; - sh:minCount 1 ; - ] ; - ] - ) ; -. -ex:ValidRectangle1 - rdf:type ex:RectangleWithArea ; - ex:height 3 ; - ex:width 2 ; -. -ex:ValidRectangle2 - rdf:type ex:RectangleWithArea ; - ex:area 6 ; - ex:height 3 ; - ex:width 2 ; -. -ex:ValidRectangle3 - rdf:type ex:RectangleWithArea ; - ex:area 6 ; - ex:height 3 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:or at node 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:InvalidRectangle1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:OrConstraintComponent ; - sh:sourceShape ex:RectangleWithArea ; - sh:value ex:InvalidRectangle1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidRectangle2 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:OrConstraintComponent ; - sh:sourceShape ex:RectangleWithArea ; - sh:value ex:InvalidRectangle2 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidRectangle1 + rdf:type ex:RectangleWithArea ; + ex:height 3 ; +. +ex:InvalidRectangle2 + rdf:type ex:RectangleWithArea ; +. +ex:RectangleWithArea + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:subClassOf rdfs:Resource ; + sh:or ( + [ + sh:property [ + sh:path ex:height ; + sh:minCount 1 ; + ] ; + sh:property [ + sh:path ex:width ; + sh:minCount 1 ; + ] ; + ] + [ + sh:property [ + sh:path ex:area ; + sh:minCount 1 ; + ] ; + ] + ) ; +. +ex:ValidRectangle1 + rdf:type ex:RectangleWithArea ; + ex:height 3 ; + ex:width 2 ; +. +ex:ValidRectangle2 + rdf:type ex:RectangleWithArea ; + ex:area 6 ; + ex:height 3 ; + ex:width 2 ; +. +ex:ValidRectangle3 + rdf:type ex:RectangleWithArea ; + ex:area 6 ; + ex:height 3 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:or at node 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:InvalidRectangle1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:OrConstraintComponent ; + sh:sourceShape ex:RectangleWithArea ; + sh:value ex:InvalidRectangle1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidRectangle2 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:OrConstraintComponent ; + sh:sourceShape ex:RectangleWithArea ; + sh:value ex:InvalidRectangle2 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/pattern-001.ttl b/shacl12-test-suite/tests/core/node/pattern-001.ttl index 31d77efc..9d895ba4 100644 --- a/shacl12-test-suite/tests/core/node/pattern-001.ttl +++ b/shacl12-test-suite/tests/core/node/pattern-001.ttl @@ -1,76 +1,76 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:pattern "^[2-8][0-9]*$" ; - sh:targetClass ex:TestClass ; - sh:targetNode ex:Test ; - sh:targetNode 20000123 ; - sh:targetNode "3456" ; - sh:targetNode 39 ; - sh:targetNode "777777"@mi ; - sh:targetNode 9 ; - sh:targetNode "John" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:pattern at node 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:Test ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:PatternConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:Test ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode 9 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:PatternConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value 9 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "John" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:PatternConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "John" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode _:b22415 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:PatternConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value _:b22415 ; - ] ; - ] ; - mf:status sht:approved ; -. -_:b22415 - rdf:type ex:TestClass ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:pattern "^[2-8][0-9]*$" ; + sh:targetClass ex:TestClass ; + sh:targetNode ex:Test ; + sh:targetNode 20000123 ; + sh:targetNode "3456" ; + sh:targetNode 39 ; + sh:targetNode "777777"@mi ; + sh:targetNode 9 ; + sh:targetNode "John" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:pattern at node 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:Test ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:PatternConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:Test ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode 9 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:PatternConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value 9 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "John" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:PatternConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "John" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode _:b22415 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:PatternConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value _:b22415 ; + ] ; + ] ; + mf:status sht:approved ; +. +_:b22415 + rdf:type ex:TestClass ; +. diff --git a/shacl12-test-suite/tests/core/node/pattern-002.ttl b/shacl12-test-suite/tests/core/node/pattern-002.ttl index fadc4d9a..2e6c963b 100644 --- a/shacl12-test-suite/tests/core/node/pattern-002.ttl +++ b/shacl12-test-suite/tests/core/node/pattern-002.ttl @@ -1,45 +1,45 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:flags "i" ; - sh:pattern "Aldi" ; - sh:targetNode "Aldi" ; - sh:targetNode "Alti" ; - sh:targetNode "aLdI" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:pattern at node shape 002" ; - 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 "Alti" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:PatternConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Alti" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:flags "i" ; + sh:pattern "Aldi" ; + sh:targetNode "Aldi" ; + sh:targetNode "Alti" ; + sh:targetNode "aLdI" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:pattern at node shape 002" ; + 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 "Alti" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:PatternConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Alti" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/qualified-001-data.ttl b/shacl12-test-suite/tests/core/node/qualified-001-data.ttl index e495305d..435f3688 100644 --- a/shacl12-test-suite/tests/core/node/qualified-001-data.ttl +++ b/shacl12-test-suite/tests/core/node/qualified-001-data.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . ex:i a ex:C1 . ex:j a ex:C1 , ex:C2 . diff --git a/shacl12-test-suite/tests/core/node/qualified-001-shapes.ttl b/shacl12-test-suite/tests/core/node/qualified-001-shapes.ttl index f430a7e0..4deb2d08 100644 --- a/shacl12-test-suite/tests/core/node/qualified-001-shapes.ttl +++ b/shacl12-test-suite/tests/core/node/qualified-001-shapes.ttl @@ -1,6 +1,6 @@ @prefix xsd: . @prefix sh: . -@prefix ex: . +@prefix ex: . ex:s1 a sh:NodeShape ; sh:targetClass ex:C1 ; diff --git a/shacl12-test-suite/tests/core/node/qualified-001.ttl b/shacl12-test-suite/tests/core/node/qualified-001.ttl index 6a89c099..5d573133 100644 --- a/shacl12-test-suite/tests/core/node/qualified-001.ttl +++ b/shacl12-test-suite/tests/core/node/qualified-001.ttl @@ -6,7 +6,7 @@ @prefix sht: . @prefix xsd: . -@prefix ex: . +@prefix ex: . <> a mf:Manifest ; mf:entries ( diff --git a/shacl12-test-suite/tests/core/node/xone-001.ttl b/shacl12-test-suite/tests/core/node/xone-001.ttl index 79011d8b..3b203737 100644 --- a/shacl12-test-suite/tests/core/node/xone-001.ttl +++ b/shacl12-test-suite/tests/core/node/xone-001.ttl @@ -1,74 +1,74 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Bob - rdf:type ex:Person ; - ex:firstName "Robert" ; - ex:lastName "Coin" ; -. -ex:Carla - rdf:type ex:Person ; - ex:fullName "Carla Miller" ; -. -ex:Dory - rdf:type ex:Person ; - ex:firstName "Dory" ; - ex:fullName "Dory Dunce" ; - ex:lastName "Dunce" ; -. -ex:XoneConstraintExampleShape - rdf:type sh:NodeShape ; - sh:targetClass ex:Person ; - sh:xone ( - [ - sh:property [ - sh:path ex:fullName ; - sh:minCount 1 ; - ] ; - ] - [ - sh:property [ - sh:path ex:firstName ; - sh:minCount 1 ; - ] ; - sh:property [ - sh:path ex:lastName ; - sh:minCount 1 ; - ] ; - ] - ) ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:xone at node 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:Dory ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:XoneConstraintComponent ; - sh:sourceShape ex:XoneConstraintExampleShape ; - sh:value ex:Dory ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Bob + rdf:type ex:Person ; + ex:firstName "Robert" ; + ex:lastName "Coin" ; +. +ex:Carla + rdf:type ex:Person ; + ex:fullName "Carla Miller" ; +. +ex:Dory + rdf:type ex:Person ; + ex:firstName "Dory" ; + ex:fullName "Dory Dunce" ; + ex:lastName "Dunce" ; +. +ex:XoneConstraintExampleShape + rdf:type sh:NodeShape ; + sh:targetClass ex:Person ; + sh:xone ( + [ + sh:property [ + sh:path ex:fullName ; + sh:minCount 1 ; + ] ; + ] + [ + sh:property [ + sh:path ex:firstName ; + sh:minCount 1 ; + ] ; + sh:property [ + sh:path ex:lastName ; + sh:minCount 1 ; + ] ; + ] + ) ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:xone at node 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:Dory ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:XoneConstraintComponent ; + sh:sourceShape ex:XoneConstraintExampleShape ; + sh:value ex:Dory ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/node/xone-duplicate-data.ttl b/shacl12-test-suite/tests/core/node/xone-duplicate-data.ttl index e495305d..435f3688 100644 --- a/shacl12-test-suite/tests/core/node/xone-duplicate-data.ttl +++ b/shacl12-test-suite/tests/core/node/xone-duplicate-data.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . ex:i a ex:C1 . ex:j a ex:C1 , ex:C2 . diff --git a/shacl12-test-suite/tests/core/node/xone-duplicate-shapes.ttl b/shacl12-test-suite/tests/core/node/xone-duplicate-shapes.ttl index eecb657d..0a26a0df 100644 --- a/shacl12-test-suite/tests/core/node/xone-duplicate-shapes.ttl +++ b/shacl12-test-suite/tests/core/node/xone-duplicate-shapes.ttl @@ -1,5 +1,5 @@ @prefix sh: . -@prefix ex: . +@prefix ex: . ex:s1 a sh:NodeShape ; sh:targetClass ex:C1 ; diff --git a/shacl12-test-suite/tests/core/node/xone-duplicate.ttl b/shacl12-test-suite/tests/core/node/xone-duplicate.ttl index 0999905f..965237cb 100644 --- a/shacl12-test-suite/tests/core/node/xone-duplicate.ttl +++ b/shacl12-test-suite/tests/core/node/xone-duplicate.ttl @@ -6,7 +6,7 @@ @prefix sht: . @prefix xsd: . -@prefix ex: . +@prefix ex: . <> a mf:Manifest ; mf:entries ( diff --git a/shacl12-test-suite/tests/core/path/path-alternative-001.ttl b/shacl12-test-suite/tests/core/path/path-alternative-001.ttl index ea267647..c30f054e 100644 --- a/shacl12-test-suite/tests/core/path/path-alternative-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-alternative-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/path/path-complex-001.ttl b/shacl12-test-suite/tests/core/path/path-complex-001.ttl index c5e20737..cf90b3a3 100644 --- a/shacl12-test-suite/tests/core/path/path-complex-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-complex-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/path/path-complex-002-data.ttl b/shacl12-test-suite/tests/core/path/path-complex-002-data.ttl index fdec8c78..70a756bb 100644 --- a/shacl12-test-suite/tests/core/path/path-complex-002-data.ttl +++ b/shacl12-test-suite/tests/core/path/path-complex-002-data.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . ex:j ex:p ex:i . diff --git a/shacl12-test-suite/tests/core/path/path-complex-002-shapes.ttl b/shacl12-test-suite/tests/core/path/path-complex-002-shapes.ttl index f9e8a73b..e7dcf968 100644 --- a/shacl12-test-suite/tests/core/path/path-complex-002-shapes.ttl +++ b/shacl12-test-suite/tests/core/path/path-complex-002-shapes.ttl @@ -1,5 +1,5 @@ @prefix sh: . -@prefix ex: . +@prefix ex: . ex:s1 a sh:PropertyShape ; sh:targetNode ex:i ; diff --git a/shacl12-test-suite/tests/core/path/path-complex-002.ttl b/shacl12-test-suite/tests/core/path/path-complex-002.ttl index fdfcfe5c..fe95a3f1 100644 --- a/shacl12-test-suite/tests/core/path/path-complex-002.ttl +++ b/shacl12-test-suite/tests/core/path/path-complex-002.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/path/path-inverse-001.ttl b/shacl12-test-suite/tests/core/path/path-inverse-001.ttl index a4c4ac4d..efeaf217 100644 --- a/shacl12-test-suite/tests/core/path/path-inverse-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-inverse-001.ttl @@ -1,90 +1,90 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - rdf:type ex:Person ; -. -ex:InvalidResource2 - rdf:type ex:Person ; -. -ex:Parent1 - ex:child ex:InvalidResource1 ; - ex:child ex:InvalidResource2 ; - ex:child ex:ValidResource1 ; -. -ex:Parent2 - ex:child ex:InvalidResource2 ; - ex:child ex:ValidResource1 ; -. -ex:Parent3 - ex:child ex:InvalidResource2 ; -. -ex:Person - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Person" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-P ; - sh:targetClass ex:Person ; -. -ex:TestShape-P - rdf:type sh:PropertyShape ; - sh:path [ - sh:inversePath ex:child ; - ] ; - sh:maxCount 2 ; - sh:minCount 2 ; -. -ex:ValidResource1 - rdf:type ex:Person ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of path sh:inversePath 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 [ - sh:inversePath ex:child ; - ] ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinCountConstraintComponent ; - sh:sourceShape ex:TestShape-P ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath [ - sh:inversePath ex:child ; - ] ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape ex:TestShape-P ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + rdf:type ex:Person ; +. +ex:InvalidResource2 + rdf:type ex:Person ; +. +ex:Parent1 + ex:child ex:InvalidResource1 ; + ex:child ex:InvalidResource2 ; + ex:child ex:ValidResource1 ; +. +ex:Parent2 + ex:child ex:InvalidResource2 ; + ex:child ex:ValidResource1 ; +. +ex:Parent3 + ex:child ex:InvalidResource2 ; +. +ex:Person + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Person" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-P ; + sh:targetClass ex:Person ; +. +ex:TestShape-P + rdf:type sh:PropertyShape ; + sh:path [ + sh:inversePath ex:child ; + ] ; + sh:maxCount 2 ; + sh:minCount 2 ; +. +ex:ValidResource1 + rdf:type ex:Person ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of path sh:inversePath 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 [ + sh:inversePath ex:child ; + ] ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinCountConstraintComponent ; + sh:sourceShape ex:TestShape-P ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath [ + sh:inversePath ex:child ; + ] ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape ex:TestShape-P ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/path/path-oneOrMore-001.ttl b/shacl12-test-suite/tests/core/path/path-oneOrMore-001.ttl index 97d4e030..91e1f6ac 100644 --- a/shacl12-test-suite/tests/core/path/path-oneOrMore-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-oneOrMore-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/path/path-sequence-001.ttl b/shacl12-test-suite/tests/core/path/path-sequence-001.ttl index 65ec5292..497ca2a3 100644 --- a/shacl12-test-suite/tests/core/path/path-sequence-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-sequence-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/path/path-sequence-002.ttl b/shacl12-test-suite/tests/core/path/path-sequence-002.ttl index 4ae6698b..ad734774 100644 --- a/shacl12-test-suite/tests/core/path/path-sequence-002.ttl +++ b/shacl12-test-suite/tests/core/path/path-sequence-002.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/path/path-sequence-duplicate-001.ttl b/shacl12-test-suite/tests/core/path/path-sequence-duplicate-001.ttl index 81264c57..76cf9af0 100644 --- a/shacl12-test-suite/tests/core/path/path-sequence-duplicate-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-sequence-duplicate-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/path/path-strange-001.ttl b/shacl12-test-suite/tests/core/path/path-strange-001.ttl index 2409cb40..757ef244 100644 --- a/shacl12-test-suite/tests/core/path/path-strange-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-strange-001.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix rdf: . @prefix rdfs: . diff --git a/shacl12-test-suite/tests/core/path/path-strange-002.ttl b/shacl12-test-suite/tests/core/path/path-strange-002.ttl index 4290f9f1..04e8c579 100644 --- a/shacl12-test-suite/tests/core/path/path-strange-002.ttl +++ b/shacl12-test-suite/tests/core/path/path-strange-002.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix rdf: . @prefix rdfs: . diff --git a/shacl12-test-suite/tests/core/path/path-unused-001-data.ttl b/shacl12-test-suite/tests/core/path/path-unused-001-data.ttl index ea38c1bb..455d7d09 100644 --- a/shacl12-test-suite/tests/core/path/path-unused-001-data.ttl +++ b/shacl12-test-suite/tests/core/path/path-unused-001-data.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . ex:i a ex:C . diff --git a/shacl12-test-suite/tests/core/path/path-unused-001-shapes.ttl b/shacl12-test-suite/tests/core/path/path-unused-001-shapes.ttl index 06838876..ed52cc14 100644 --- a/shacl12-test-suite/tests/core/path/path-unused-001-shapes.ttl +++ b/shacl12-test-suite/tests/core/path/path-unused-001-shapes.ttl @@ -1,5 +1,5 @@ @prefix sh: . -@prefix ex: . +@prefix ex: . @prefix rdf: . @prefix rdfs: . diff --git a/shacl12-test-suite/tests/core/path/path-unused-001.ttl b/shacl12-test-suite/tests/core/path/path-unused-001.ttl index 4ae29091..9b7ef0b3 100644 --- a/shacl12-test-suite/tests/core/path/path-unused-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-unused-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/path/path-zeroOrMore-001.ttl b/shacl12-test-suite/tests/core/path/path-zeroOrMore-001.ttl index 834ab9f1..60c033b7 100644 --- a/shacl12-test-suite/tests/core/path/path-zeroOrMore-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-zeroOrMore-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/path/path-zeroOrOne-001.ttl b/shacl12-test-suite/tests/core/path/path-zeroOrOne-001.ttl index 2e4e34f5..c30c270e 100644 --- a/shacl12-test-suite/tests/core/path/path-zeroOrOne-001.ttl +++ b/shacl12-test-suite/tests/core/path/path-zeroOrOne-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/property/and-001.ttl b/shacl12-test-suite/tests/core/property/and-001.ttl index 57eeaf45..2bcd0b63 100644 --- a/shacl12-test-suite/tests/core/property/and-001.ttl +++ b/shacl12-test-suite/tests/core/property/and-001.ttl @@ -1,107 +1,107 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:AddressShape - rdf:type sh:NodeShape ; - rdfs:label "Address shape" ; - sh:property ex:AddressShape-address ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:InvalidResource2 ; - sh:targetNode ex:InvalidResource3 ; - sh:targetNode ex:ValidResource1 ; -. -ex:AddressShape-address - sh:path ex:address ; - sh:and ( - [ - sh:property [ - sh:path ex:suburb ; - sh:minCount 1 ; - ] ; - ] - [ - sh:property [ - sh:path ex:postalCode ; - sh:minCount 1 ; - ] ; - ] - ) ; -. -ex:InvalidResource1 - rdf:type rdfs:Resource ; - ex:address _:b61065 ; -. -ex:InvalidResource2 - rdf:type rdfs:Resource ; - ex:address _:b31477 ; -. -ex:InvalidResource3 - rdf:type rdfs:Resource ; - ex:address _:b94057 ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; - ex:address [ - ex:postalCode 4879 ; - ex:suburb ex:KewarraBeach ; - ] ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:and 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:address ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:AndConstraintComponent ; - sh:sourceShape ex:AddressShape-address ; - sh:value _:b61065 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath ex:address ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:AndConstraintComponent ; - sh:sourceShape ex:AddressShape-address ; - sh:value _:b31477 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource3 ; - sh:resultPath ex:address ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:AndConstraintComponent ; - sh:sourceShape ex:AddressShape-address ; - sh:value _:b94057 ; - ] ; - ] ; - mf:status sht:approved ; -. -_:b31477 - ex:suburb ex:KewarraBeach ; -. -_:b61065 - ex:postalCode 4879 ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:AddressShape + rdf:type sh:NodeShape ; + rdfs:label "Address shape" ; + sh:property ex:AddressShape-address ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:InvalidResource2 ; + sh:targetNode ex:InvalidResource3 ; + sh:targetNode ex:ValidResource1 ; +. +ex:AddressShape-address + sh:path ex:address ; + sh:and ( + [ + sh:property [ + sh:path ex:suburb ; + sh:minCount 1 ; + ] ; + ] + [ + sh:property [ + sh:path ex:postalCode ; + sh:minCount 1 ; + ] ; + ] + ) ; +. +ex:InvalidResource1 + rdf:type rdfs:Resource ; + ex:address _:b61065 ; +. +ex:InvalidResource2 + rdf:type rdfs:Resource ; + ex:address _:b31477 ; +. +ex:InvalidResource3 + rdf:type rdfs:Resource ; + ex:address _:b94057 ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; + ex:address [ + ex:postalCode 4879 ; + ex:suburb ex:KewarraBeach ; + ] ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:and 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:address ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:AndConstraintComponent ; + sh:sourceShape ex:AddressShape-address ; + sh:value _:b61065 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath ex:address ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:AndConstraintComponent ; + sh:sourceShape ex:AddressShape-address ; + sh:value _:b31477 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource3 ; + sh:resultPath ex:address ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:AndConstraintComponent ; + sh:sourceShape ex:AddressShape-address ; + sh:value _:b94057 ; + ] ; + ] ; + mf:status sht:approved ; +. +_:b31477 + ex:suburb ex:KewarraBeach ; +. +_:b61065 + ex:postalCode 4879 ; +. diff --git a/shacl12-test-suite/tests/core/property/class-001.ttl b/shacl12-test-suite/tests/core/property/class-001.ttl index 2b97bf82..ec0d3b52 100644 --- a/shacl12-test-suite/tests/core/property/class-001.ttl +++ b/shacl12-test-suite/tests/core/property/class-001.ttl @@ -1,91 +1,91 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - rdf:type rdfs:Resource ; - ex:testProperty ex:InvalidResource1 ; - ex:testProperty "A string" ; -. -ex:SubClass - rdf:type rdfs:Class ; - rdfs:subClassOf ex:SuperClass ; -. -ex:SubClassInstance - rdf:type ex:SubClass ; -. -ex:SuperClass - rdf:type rdfs:Class ; -. -ex:SuperClassInstance - rdf:type ex:SuperClass ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-testProperty ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:ValidResource1 ; - sh:targetNode ex:ValidResource2 ; -. -ex:TestShape-testProperty - sh:path ex:testProperty ; - rdfs:label "test property" ; - sh:class ex:SuperClass ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; - ex:testProperty ex:SubClassInstance ; - ex:testProperty ex:SuperClassInstance ; -. -ex:ValidResource2 - rdf:type rdfs:Resource ; - ex:testProperty [ - rdf:type ex:SubClass ; - ] ; - ex:testProperty [ - rdf:type ex:SuperClass ; - ] ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:class 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:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - sh:value ex:InvalidResource1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource1 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - sh:value "A string" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + rdf:type rdfs:Resource ; + ex:testProperty ex:InvalidResource1 ; + ex:testProperty "A string" ; +. +ex:SubClass + rdf:type rdfs:Class ; + rdfs:subClassOf ex:SuperClass ; +. +ex:SubClassInstance + rdf:type ex:SubClass ; +. +ex:SuperClass + rdf:type rdfs:Class ; +. +ex:SuperClassInstance + rdf:type ex:SuperClass ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-testProperty ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:ValidResource1 ; + sh:targetNode ex:ValidResource2 ; +. +ex:TestShape-testProperty + sh:path ex:testProperty ; + rdfs:label "test property" ; + sh:class ex:SuperClass ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; + ex:testProperty ex:SubClassInstance ; + ex:testProperty ex:SuperClassInstance ; +. +ex:ValidResource2 + rdf:type rdfs:Resource ; + ex:testProperty [ + rdf:type ex:SubClass ; + ] ; + ex:testProperty [ + rdf:type ex:SuperClass ; + ] ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:class 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:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + sh:value ex:InvalidResource1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource1 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + sh:value "A string" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/datatype-001.ttl b/shacl12-test-suite/tests/core/property/datatype-001.ttl index f1b1b814..f2bbf9f1 100644 --- a/shacl12-test-suite/tests/core/property/datatype-001.ttl +++ b/shacl12-test-suite/tests/core/property/datatype-001.ttl @@ -1,76 +1,76 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - rdf:type ex:TestShape ; - ex:dateProperty "2011-01-01"^^xsd:dateTime ; - ex:integerProperty 11.1 ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-dateProperty ; - sh:property ex:TestShape-integerProperty ; -. -ex:TestShape-dateProperty - sh:path ex:dateProperty ; - rdfs:label "date property" ; - sh:datatype xsd:date ; -. -ex:TestShape-integerProperty - sh:path ex:integerProperty ; - rdfs:label "integer property" ; - sh:datatype xsd:integer ; -. -ex:ValidResource - rdf:type ex:TestShape ; - ex:dateProperty "2014-09-01"^^xsd:date ; - ex:integerProperty 0 ; - ex:integerProperty 1234 ; - rdfs:label "Valid resource" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:datatype 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:dateProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; - sh:sourceShape ex:TestShape-dateProperty ; - sh:value "2011-01-01"^^xsd:dateTime ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource1 ; - sh:resultPath ex:integerProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; - sh:sourceShape ex:TestShape-integerProperty ; - sh:value 11.1 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + rdf:type ex:TestShape ; + ex:dateProperty "2011-01-01"^^xsd:dateTime ; + ex:integerProperty 11.1 ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-dateProperty ; + sh:property ex:TestShape-integerProperty ; +. +ex:TestShape-dateProperty + sh:path ex:dateProperty ; + rdfs:label "date property" ; + sh:datatype xsd:date ; +. +ex:TestShape-integerProperty + sh:path ex:integerProperty ; + rdfs:label "integer property" ; + sh:datatype xsd:integer ; +. +ex:ValidResource + rdf:type ex:TestShape ; + ex:dateProperty "2014-09-01"^^xsd:date ; + ex:integerProperty 0 ; + ex:integerProperty 1234 ; + rdfs:label "Valid resource" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:datatype 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:dateProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; + sh:sourceShape ex:TestShape-dateProperty ; + sh:value "2011-01-01"^^xsd:dateTime ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource1 ; + sh:resultPath ex:integerProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; + sh:sourceShape ex:TestShape-integerProperty ; + sh:value 11.1 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/datatype-002.ttl b/shacl12-test-suite/tests/core/property/datatype-002.ttl index fc563774..24fd1b4b 100644 --- a/shacl12-test-suite/tests/core/property/datatype-002.ttl +++ b/shacl12-test-suite/tests/core/property/datatype-002.ttl @@ -1,71 +1,71 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - ex:value "A"@en ; -. -ex:InvalidInstance2 - ex:value 42 ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-value ; - sh:targetNode ex:InvalidInstance1 ; - sh:targetNode ex:InvalidInstance2 ; - sh:targetNode ex:ValidInstance1 ; - sh:targetNode ex:ValidInstance2 ; -. -ex:TestShape-value - sh:path ex:value ; - sh:datatype xsd:string ; -. -ex:ValidInstance1 - ex:value "A" ; -. -ex:ValidInstance2 - ex:value "A" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:datatype at property shape 002" ; - 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:InvalidInstance1 ; - sh:resultPath ex:value ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; - sh:sourceShape ex:TestShape-value ; - sh:value "A"@en ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance2 ; - sh:resultPath ex:value ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; - sh:sourceShape ex:TestShape-value ; - sh:value 42 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + ex:value "A"@en ; +. +ex:InvalidInstance2 + ex:value 42 ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-value ; + sh:targetNode ex:InvalidInstance1 ; + sh:targetNode ex:InvalidInstance2 ; + sh:targetNode ex:ValidInstance1 ; + sh:targetNode ex:ValidInstance2 ; +. +ex:TestShape-value + sh:path ex:value ; + sh:datatype xsd:string ; +. +ex:ValidInstance1 + ex:value "A" ; +. +ex:ValidInstance2 + ex:value "A" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:datatype at property shape 002" ; + 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:InvalidInstance1 ; + sh:resultPath ex:value ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; + sh:sourceShape ex:TestShape-value ; + sh:value "A"@en ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance2 ; + sh:resultPath ex:value ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; + sh:sourceShape ex:TestShape-value ; + sh:value 42 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/datatype-003.ttl b/shacl12-test-suite/tests/core/property/datatype-003.ttl index 52968507..f34bb622 100644 --- a/shacl12-test-suite/tests/core/property/datatype-003.ttl +++ b/shacl12-test-suite/tests/core/property/datatype-003.ttl @@ -1,69 +1,69 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - ex:value 42 ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-value ; - sh:targetNode ex:InvalidInstance1 ; - sh:targetNode ex:ValidInstance1 ; - sh:targetNode ex:ValidInstance2 ; - sh:targetNode ex:ValidInstance3 ; -. -ex:TestShape-value - sh:path ex:value ; - sh:or ( - [ - sh:datatype xsd:string ; - ] - [ - sh:datatype rdf:langString ; - ] - ) ; -. -ex:ValidInstance1 - ex:value "A" ; -. -ex:ValidInstance2 - ex:value "A" ; -. -ex:ValidInstance3 - ex:value "A"@en ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:datatype at property shape 003" ; - 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:InvalidInstance1 ; - sh:resultPath ex:value ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:OrConstraintComponent ; - sh:sourceShape ex:TestShape-value ; - sh:value 42 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + ex:value 42 ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-value ; + sh:targetNode ex:InvalidInstance1 ; + sh:targetNode ex:ValidInstance1 ; + sh:targetNode ex:ValidInstance2 ; + sh:targetNode ex:ValidInstance3 ; +. +ex:TestShape-value + sh:path ex:value ; + sh:or ( + [ + sh:datatype xsd:string ; + ] + [ + sh:datatype rdf:langString ; + ] + ) ; +. +ex:ValidInstance1 + ex:value "A" ; +. +ex:ValidInstance2 + ex:value "A" ; +. +ex:ValidInstance3 + ex:value "A"@en ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:datatype at property shape 003" ; + 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:InvalidInstance1 ; + sh:resultPath ex:value ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:OrConstraintComponent ; + sh:sourceShape ex:TestShape-value ; + sh:value 42 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/datatype-ill-formed-data.ttl b/shacl12-test-suite/tests/core/property/datatype-ill-formed-data.ttl index e5338afa..90776a13 100644 --- a/shacl12-test-suite/tests/core/property/datatype-ill-formed-data.ttl +++ b/shacl12-test-suite/tests/core/property/datatype-ill-formed-data.ttl @@ -1,5 +1,5 @@ @prefix xsd: . -@prefix ex: . +@prefix ex: . ex:i ex:p "300"^^xsd:byte . ex:i ex:p "55"^^xsd:integer . diff --git a/shacl12-test-suite/tests/core/property/datatype-ill-formed-shapes.ttl b/shacl12-test-suite/tests/core/property/datatype-ill-formed-shapes.ttl index 20366326..248127a5 100644 --- a/shacl12-test-suite/tests/core/property/datatype-ill-formed-shapes.ttl +++ b/shacl12-test-suite/tests/core/property/datatype-ill-formed-shapes.ttl @@ -1,6 +1,6 @@ @prefix sh: . @prefix xsd: . -@prefix ex: . +@prefix ex: . ex:s a sh:PropertyShape ; sh:targetNode ex:i ; diff --git a/shacl12-test-suite/tests/core/property/datatype-ill-formed.ttl b/shacl12-test-suite/tests/core/property/datatype-ill-formed.ttl index 08611e49..6c05db3d 100644 --- a/shacl12-test-suite/tests/core/property/datatype-ill-formed.ttl +++ b/shacl12-test-suite/tests/core/property/datatype-ill-formed.ttl @@ -6,7 +6,7 @@ @prefix sht: . @prefix xsd: . -@prefix ex: . +@prefix ex: . <> rdf:type mf:Manifest ; mf:entries ( diff --git a/shacl12-test-suite/tests/core/property/disjoint-001.ttl b/shacl12-test-suite/tests/core/property/disjoint-001.ttl index 8bfc6852..f92a940c 100644 --- a/shacl12-test-suite/tests/core/property/disjoint-001.ttl +++ b/shacl12-test-suite/tests/core/property/disjoint-001.ttl @@ -1,84 +1,84 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:property1 "A" ; - ex:property2 "A" ; -. -ex:InvalidResource2 - ex:property1 "A" ; - ex:property1 "B" ; - ex:property2 "A" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-property1 ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:InvalidResource2 ; - sh:targetNode ex:ValidResource1 ; - sh:targetNode ex:ValidResource2 ; -. -ex:TestShape-property1 - sh:path ex:property1 ; - sh:disjoint ex:property2 ; -. -ex:ValidResource1 - ex:property1 "A" ; - ex:property2 "B" ; -. -ex:ValidResource2 - ex:property1 "A" ; - ex:property1 "B" ; - ex:property2 "C" ; - ex:property2 "D" ; -. -ex:property1 - rdf:type rdf:Property ; -. -ex:property2 - rdf:type rdf:Property ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:disjoint 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:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DisjointConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value "A" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath ex:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DisjointConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value "A" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:property1 "A" ; + ex:property2 "A" ; +. +ex:InvalidResource2 + ex:property1 "A" ; + ex:property1 "B" ; + ex:property2 "A" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-property1 ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:InvalidResource2 ; + sh:targetNode ex:ValidResource1 ; + sh:targetNode ex:ValidResource2 ; +. +ex:TestShape-property1 + sh:path ex:property1 ; + sh:disjoint ex:property2 ; +. +ex:ValidResource1 + ex:property1 "A" ; + ex:property2 "B" ; +. +ex:ValidResource2 + ex:property1 "A" ; + ex:property1 "B" ; + ex:property2 "C" ; + ex:property2 "D" ; +. +ex:property1 + rdf:type rdf:Property ; +. +ex:property2 + rdf:type rdf:Property ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:disjoint 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:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DisjointConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value "A" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath ex:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DisjointConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value "A" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/equals-001.ttl b/shacl12-test-suite/tests/core/property/equals-001.ttl index 64024cd4..290f2d52 100644 --- a/shacl12-test-suite/tests/core/property/equals-001.ttl +++ b/shacl12-test-suite/tests/core/property/equals-001.ttl @@ -1,119 +1,119 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:property1 "A" ; - ex:property2 "B" ; -. -ex:InvalidResource2 - ex:property1 "A" ; -. -ex:InvalidResource3 - ex:property2 "A" ; -. -ex:InvalidResource4 - ex:property1 "A" ; - ex:property1 "B" ; - ex:property2 "A" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-property1 ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:InvalidResource2 ; - sh:targetNode ex:InvalidResource3 ; - sh:targetNode ex:InvalidResource4 ; - sh:targetNode ex:ValidResource1 ; - sh:targetNode ex:ValidResource2 ; -. -ex:TestShape-property1 - sh:path ex:property1 ; - sh:equals ex:property2 ; -. -ex:ValidResource1 - ex:property1 "A" ; - ex:property2 "A" ; -. -ex:ValidResource2 - ex:property1 "A" ; - ex:property1 "B" ; - ex:property2 "A" ; - ex:property2 "B" ; -. -ex:property1 - rdf:type rdf:Property ; -. -ex:property2 - rdf:type rdf:Property ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:equals 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:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:EqualsConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value "A" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource1 ; - sh:resultPath ex:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:EqualsConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value "B" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath ex:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:EqualsConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value "A" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource3 ; - sh:resultPath ex:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:EqualsConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value "A" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource4 ; - sh:resultPath ex:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:EqualsConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value "B" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:property1 "A" ; + ex:property2 "B" ; +. +ex:InvalidResource2 + ex:property1 "A" ; +. +ex:InvalidResource3 + ex:property2 "A" ; +. +ex:InvalidResource4 + ex:property1 "A" ; + ex:property1 "B" ; + ex:property2 "A" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-property1 ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:InvalidResource2 ; + sh:targetNode ex:InvalidResource3 ; + sh:targetNode ex:InvalidResource4 ; + sh:targetNode ex:ValidResource1 ; + sh:targetNode ex:ValidResource2 ; +. +ex:TestShape-property1 + sh:path ex:property1 ; + sh:equals ex:property2 ; +. +ex:ValidResource1 + ex:property1 "A" ; + ex:property2 "A" ; +. +ex:ValidResource2 + ex:property1 "A" ; + ex:property1 "B" ; + ex:property2 "A" ; + ex:property2 "B" ; +. +ex:property1 + rdf:type rdf:Property ; +. +ex:property2 + rdf:type rdf:Property ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:equals 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:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:EqualsConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value "A" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource1 ; + sh:resultPath ex:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:EqualsConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value "B" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath ex:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:EqualsConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value "A" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource3 ; + sh:resultPath ex:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:EqualsConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value "A" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource4 ; + sh:resultPath ex:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:EqualsConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value "B" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/hasValue-001.ttl b/shacl12-test-suite/tests/core/property/hasValue-001.ttl index ffaa0ebb..ebec5e9e 100644 --- a/shacl12-test-suite/tests/core/property/hasValue-001.ttl +++ b/shacl12-test-suite/tests/core/property/hasValue-001.ttl @@ -1,68 +1,68 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidMalePerson - rdf:type ex:MalePerson ; - ex:gender "female" ; - rdfs:label "Invalid male person" ; -. -ex:MalePerson - rdf:type rdfs:Class ; - rdfs:label "Male person" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:PersonShape - rdf:type sh:NodeShape ; - rdfs:label "Person shape" ; - sh:property ex:PersonShape-gender ; - sh:targetClass ex:MalePerson ; -. -ex:PersonShape-gender - sh:path ex:gender ; - rdfs:label "gender" ; - sh:datatype xsd:string ; - sh:hasValue "male" ; -. -ex:ValidMalePerson1 - rdf:type ex:MalePerson ; - ex:gender "male" ; -. -ex:ValidMalePerson2 - rdf:type ex:MalePerson ; - ex:gender "female" ; - ex:gender "male" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:hasValue 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:InvalidMalePerson ; - sh:resultPath ex:gender ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:HasValueConstraintComponent ; - sh:sourceShape ex:PersonShape-gender ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidMalePerson + rdf:type ex:MalePerson ; + ex:gender "female" ; + rdfs:label "Invalid male person" ; +. +ex:MalePerson + rdf:type rdfs:Class ; + rdfs:label "Male person" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:PersonShape + rdf:type sh:NodeShape ; + rdfs:label "Person shape" ; + sh:property ex:PersonShape-gender ; + sh:targetClass ex:MalePerson ; +. +ex:PersonShape-gender + sh:path ex:gender ; + rdfs:label "gender" ; + sh:datatype xsd:string ; + sh:hasValue "male" ; +. +ex:ValidMalePerson1 + rdf:type ex:MalePerson ; + ex:gender "male" ; +. +ex:ValidMalePerson2 + rdf:type ex:MalePerson ; + ex:gender "female" ; + ex:gender "male" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:hasValue 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:InvalidMalePerson ; + sh:resultPath ex:gender ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:HasValueConstraintComponent ; + sh:sourceShape ex:PersonShape-gender ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/in-001.ttl b/shacl12-test-suite/tests/core/property/in-001.ttl index cfd37cfb..e7f6ba7f 100644 --- a/shacl12-test-suite/tests/core/property/in-001.ttl +++ b/shacl12-test-suite/tests/core/property/in-001.ttl @@ -1,69 +1,69 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:ShapeClass ; - ex:property "D" ; - rdfs:label "Invalid instance1" ; -. -ex:ShapeClass - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - sh:property ex:ShapeClass-property ; -. -ex:ShapeClass-property - sh:path ex:property ; - sh:datatype xsd:string ; - sh:in ( - "A" - "B" - "C" - ) ; -. -ex:ValidInstance1 - rdf:type ex:ShapeClass ; - ex:property "A" ; - rdfs:label "Valid instance1" ; -. -ex:ValidInstance2 - rdf:type ex:ShapeClass ; - ex:property "A" ; - ex:property "B" ; - ex:property "C" ; - rdfs:label "Valid instance2" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:in 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:InvalidInstance1 ; - sh:resultPath ex:property ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:InConstraintComponent ; - sh:sourceShape ex:ShapeClass-property ; - sh:value "D" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:ShapeClass ; + ex:property "D" ; + rdfs:label "Invalid instance1" ; +. +ex:ShapeClass + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + sh:property ex:ShapeClass-property ; +. +ex:ShapeClass-property + sh:path ex:property ; + sh:datatype xsd:string ; + sh:in ( + "A" + "B" + "C" + ) ; +. +ex:ValidInstance1 + rdf:type ex:ShapeClass ; + ex:property "A" ; + rdfs:label "Valid instance1" ; +. +ex:ValidInstance2 + rdf:type ex:ShapeClass ; + ex:property "A" ; + ex:property "B" ; + ex:property "C" ; + rdfs:label "Valid instance2" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:in 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:InvalidInstance1 ; + sh:resultPath ex:property ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:InConstraintComponent ; + sh:sourceShape ex:ShapeClass-property ; + sh:value "D" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/languageIn-001.ttl b/shacl12-test-suite/tests/core/property/languageIn-001.ttl index 00e9d98b..86ef3609 100644 --- a/shacl12-test-suite/tests/core/property/languageIn-001.ttl +++ b/shacl12-test-suite/tests/core/property/languageIn-001.ttl @@ -1,79 +1,79 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Berg - ex:prefLabel ex:BergLabel ; - ex:prefLabel "Berg" ; - ex:prefLabel "Berg"@de ; -. -ex:Mountain - ex:prefLabel "Hill"@en-NZ ; - ex:prefLabel "Maunga"@mi ; - ex:prefLabel "Mountain"@en ; -. -ex:NewZealandLanguagesShape - rdf:type sh:NodeShape ; - sh:property ex:NewZealandLanguagesShape-prefLabel ; - sh:targetNode ex:Berg ; - sh:targetNode ex:Mountain ; -. -ex:NewZealandLanguagesShape-prefLabel - sh:path ex:prefLabel ; - sh:languageIn ( - "en" - "mi" - ) ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:languageIn 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:Berg ; - sh:resultPath ex:prefLabel ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; - sh:sourceShape ex:NewZealandLanguagesShape-prefLabel ; - sh:value ex:BergLabel ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:Berg ; - sh:resultPath ex:prefLabel ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; - sh:sourceShape ex:NewZealandLanguagesShape-prefLabel ; - sh:value "Berg" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:Berg ; - sh:resultPath ex:prefLabel ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; - sh:sourceShape ex:NewZealandLanguagesShape-prefLabel ; - sh:value "Berg"@de ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Berg + ex:prefLabel ex:BergLabel ; + ex:prefLabel "Berg" ; + ex:prefLabel "Berg"@de ; +. +ex:Mountain + ex:prefLabel "Hill"@en-NZ ; + ex:prefLabel "Maunga"@mi ; + ex:prefLabel "Mountain"@en ; +. +ex:NewZealandLanguagesShape + rdf:type sh:NodeShape ; + sh:property ex:NewZealandLanguagesShape-prefLabel ; + sh:targetNode ex:Berg ; + sh:targetNode ex:Mountain ; +. +ex:NewZealandLanguagesShape-prefLabel + sh:path ex:prefLabel ; + sh:languageIn ( + "en" + "mi" + ) ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:languageIn 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:Berg ; + sh:resultPath ex:prefLabel ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; + sh:sourceShape ex:NewZealandLanguagesShape-prefLabel ; + sh:value ex:BergLabel ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:Berg ; + sh:resultPath ex:prefLabel ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; + sh:sourceShape ex:NewZealandLanguagesShape-prefLabel ; + sh:value "Berg" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:Berg ; + sh:resultPath ex:prefLabel ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LanguageInConstraintComponent ; + sh:sourceShape ex:NewZealandLanguagesShape-prefLabel ; + sh:value "Berg"@de ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/lessThan-001.ttl b/shacl12-test-suite/tests/core/property/lessThan-001.ttl index d76b37da..dcdd3872 100644 --- a/shacl12-test-suite/tests/core/property/lessThan-001.ttl +++ b/shacl12-test-suite/tests/core/property/lessThan-001.ttl @@ -1,96 +1,96 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:property1 4 ; - ex:property2 4 ; -. -ex:InvalidResource2 - ex:property1 4 ; - ex:property1 6 ; - ex:property2 5 ; -. -ex:InvalidResource3 - ex:property1 5 ; - ex:property2 4 ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-property1 ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:InvalidResource2 ; - sh:targetNode ex:InvalidResource3 ; - sh:targetNode ex:ValidResource1 ; - sh:targetNode ex:ValidResource2 ; -. -ex:TestShape-property1 - sh:path ex:property1 ; - sh:lessThan ex:property2 ; -. -ex:ValidResource1 - ex:property1 4 ; - ex:property2 6 ; -. -ex:ValidResource2 - ex:property1 3.1 ; - ex:property1 3.2 ; -. -ex:property1 - rdf:type rdf:Property ; -. -ex:property2 - rdf:type rdf:Property ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:lessThan 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:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LessThanConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value 4 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath ex:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LessThanConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value 6 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource3 ; - sh:resultPath ex:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LessThanConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value 5 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:property1 4 ; + ex:property2 4 ; +. +ex:InvalidResource2 + ex:property1 4 ; + ex:property1 6 ; + ex:property2 5 ; +. +ex:InvalidResource3 + ex:property1 5 ; + ex:property2 4 ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-property1 ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:InvalidResource2 ; + sh:targetNode ex:InvalidResource3 ; + sh:targetNode ex:ValidResource1 ; + sh:targetNode ex:ValidResource2 ; +. +ex:TestShape-property1 + sh:path ex:property1 ; + sh:lessThan ex:property2 ; +. +ex:ValidResource1 + ex:property1 4 ; + ex:property2 6 ; +. +ex:ValidResource2 + ex:property1 3.1 ; + ex:property1 3.2 ; +. +ex:property1 + rdf:type rdf:Property ; +. +ex:property2 + rdf:type rdf:Property ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:lessThan 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:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LessThanConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value 4 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath ex:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LessThanConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value 6 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource3 ; + sh:resultPath ex:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LessThanConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value 5 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/lessThan-002.ttl b/shacl12-test-suite/tests/core/property/lessThan-002.ttl index 9f352ef3..e4e8a80b 100644 --- a/shacl12-test-suite/tests/core/property/lessThan-002.ttl +++ b/shacl12-test-suite/tests/core/property/lessThan-002.ttl @@ -1,81 +1,81 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - ex:first 1 ; - ex:first 2 ; - ex:second "a" ; - ex:second "b" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-first ; - sh:targetNode ex:InvalidInstance1 ; -. -ex:TestShape-first - sh:path ex:first ; - sh:lessThan ex:second ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:lessThan at property shape 002" ; - 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:InvalidInstance1 ; - sh:resultPath ex:first ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LessThanConstraintComponent ; - sh:sourceShape ex:TestShape-first ; - sh:value 1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance1 ; - sh:resultPath ex:first ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LessThanConstraintComponent ; - sh:sourceShape ex:TestShape-first ; - sh:value 1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance1 ; - sh:resultPath ex:first ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LessThanConstraintComponent ; - sh:sourceShape ex:TestShape-first ; - sh:value 2 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance1 ; - sh:resultPath ex:first ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LessThanConstraintComponent ; - sh:sourceShape ex:TestShape-first ; - sh:value 2 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + ex:first 1 ; + ex:first 2 ; + ex:second "a" ; + ex:second "b" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-first ; + sh:targetNode ex:InvalidInstance1 ; +. +ex:TestShape-first + sh:path ex:first ; + sh:lessThan ex:second ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:lessThan at property shape 002" ; + 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:InvalidInstance1 ; + sh:resultPath ex:first ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LessThanConstraintComponent ; + sh:sourceShape ex:TestShape-first ; + sh:value 1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance1 ; + sh:resultPath ex:first ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LessThanConstraintComponent ; + sh:sourceShape ex:TestShape-first ; + sh:value 1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance1 ; + sh:resultPath ex:first ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LessThanConstraintComponent ; + sh:sourceShape ex:TestShape-first ; + sh:value 2 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance1 ; + sh:resultPath ex:first ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LessThanConstraintComponent ; + sh:sourceShape ex:TestShape-first ; + sh:value 2 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/lessThanOrEquals-001.ttl b/shacl12-test-suite/tests/core/property/lessThanOrEquals-001.ttl index c1ac111c..40996241 100644 --- a/shacl12-test-suite/tests/core/property/lessThanOrEquals-001.ttl +++ b/shacl12-test-suite/tests/core/property/lessThanOrEquals-001.ttl @@ -1,87 +1,87 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:property1 5 ; - ex:property2 4 ; -. -ex:InvalidResource2 - ex:property1 4 ; - ex:property1 6 ; - ex:property2 5 ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-property1 ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:InvalidResource2 ; - sh:targetNode ex:ValidResource1 ; - sh:targetNode ex:ValidResource2 ; - sh:targetNode ex:ValidResource3 ; -. -ex:TestShape-property1 - sh:path ex:property1 ; - sh:lessThanOrEquals ex:property2 ; -. -ex:ValidResource1 - ex:property1 4 ; - ex:property2 6 ; -. -ex:ValidResource2 - ex:property1 3.1 ; - ex:property1 3.2 ; -. -ex:ValidResource3 - ex:property1 5 ; - ex:property2 5 ; -. -ex:property1 - rdf:type rdf:Property ; -. -ex:property2 - rdf:type rdf:Property ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:lessThanOrEquals 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:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LessThanOrEqualsConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value 5 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath ex:property1 ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:LessThanOrEqualsConstraintComponent ; - sh:sourceShape ex:TestShape-property1 ; - sh:value 6 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:property1 5 ; + ex:property2 4 ; +. +ex:InvalidResource2 + ex:property1 4 ; + ex:property1 6 ; + ex:property2 5 ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-property1 ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:InvalidResource2 ; + sh:targetNode ex:ValidResource1 ; + sh:targetNode ex:ValidResource2 ; + sh:targetNode ex:ValidResource3 ; +. +ex:TestShape-property1 + sh:path ex:property1 ; + sh:lessThanOrEquals ex:property2 ; +. +ex:ValidResource1 + ex:property1 4 ; + ex:property2 6 ; +. +ex:ValidResource2 + ex:property1 3.1 ; + ex:property1 3.2 ; +. +ex:ValidResource3 + ex:property1 5 ; + ex:property2 5 ; +. +ex:property1 + rdf:type rdf:Property ; +. +ex:property2 + rdf:type rdf:Property ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:lessThanOrEquals 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:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LessThanOrEqualsConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value 5 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath ex:property1 ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:LessThanOrEqualsConstraintComponent ; + sh:sourceShape ex:TestShape-property1 ; + sh:value 6 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/maxCount-001.ttl b/shacl12-test-suite/tests/core/property/maxCount-001.ttl index 52653dec..472761b9 100644 --- a/shacl12-test-suite/tests/core/property/maxCount-001.ttl +++ b/shacl12-test-suite/tests/core/property/maxCount-001.ttl @@ -1,64 +1,64 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidPerson - rdf:type ex:Person ; - ex:firstName "George" ; - ex:firstName "John" ; - rdfs:label "Invalid person" ; -. -ex:Person - rdf:type rdfs:Class ; - rdfs:label "Person" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:PersonShape - rdf:type sh:NodeShape ; - sh:property ex:PersonShape-firstName ; - sh:targetClass ex:Person ; - sh:targetNode ex:ValidResource ; -. -ex:PersonShape-firstName - sh:path ex:firstName ; - sh:datatype xsd:string ; - sh:maxCount 1 ; -. -ex:ValidResource - rdf:type ex:Person ; - ex:firstName "John" ; - rdfs:label "Valid resource" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:maxCount 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:InvalidPerson ; - sh:resultPath ex:firstName ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape ex:PersonShape-firstName ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidPerson + rdf:type ex:Person ; + ex:firstName "George" ; + ex:firstName "John" ; + rdfs:label "Invalid person" ; +. +ex:Person + rdf:type rdfs:Class ; + rdfs:label "Person" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:PersonShape + rdf:type sh:NodeShape ; + sh:property ex:PersonShape-firstName ; + sh:targetClass ex:Person ; + sh:targetNode ex:ValidResource ; +. +ex:PersonShape-firstName + sh:path ex:firstName ; + sh:datatype xsd:string ; + sh:maxCount 1 ; +. +ex:ValidResource + rdf:type ex:Person ; + ex:firstName "John" ; + rdfs:label "Valid resource" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:maxCount 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:InvalidPerson ; + sh:resultPath ex:firstName ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape ex:PersonShape-firstName ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/maxCount-002.ttl b/shacl12-test-suite/tests/core/property/maxCount-002.ttl index 23d82a07..780e5486 100644 --- a/shacl12-test-suite/tests/core/property/maxCount-002.ttl +++ b/shacl12-test-suite/tests/core/property/maxCount-002.ttl @@ -1,57 +1,57 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource - rdf:type rdfs:Resource ; - rdfs:label "Invalid resource" ; - owl:versionInfo "1.0" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-versionInfo ; - sh:targetNode ex:InvalidResource ; - sh:targetNode ex:ValidResource ; -. -ex:TestShape-versionInfo - sh:path owl:versionInfo ; - sh:maxCount 0 ; -. -ex:ValidResource - rdf:type rdfs:Resource ; - rdfs:label "Valid resource" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:maxCount at property shape 002" ; - 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:InvalidResource ; - sh:resultPath owl:versionInfo ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape ex:TestShape-versionInfo ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource + rdf:type rdfs:Resource ; + rdfs:label "Invalid resource" ; + owl:versionInfo "1.0" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-versionInfo ; + sh:targetNode ex:InvalidResource ; + sh:targetNode ex:ValidResource ; +. +ex:TestShape-versionInfo + sh:path owl:versionInfo ; + sh:maxCount 0 ; +. +ex:ValidResource + rdf:type rdfs:Resource ; + rdfs:label "Valid resource" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:maxCount at property shape 002" ; + 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:InvalidResource ; + sh:resultPath owl:versionInfo ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape ex:TestShape-versionInfo ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/maxExclusive-001.ttl b/shacl12-test-suite/tests/core/property/maxExclusive-001.ttl index 47566a8f..34e6357f 100644 --- a/shacl12-test-suite/tests/core/property/maxExclusive-001.ttl +++ b/shacl12-test-suite/tests/core/property/maxExclusive-001.ttl @@ -1,84 +1,84 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:property 1 ; -. -ex:InvalidResource2 - ex:property 2 ; -. -ex:InvalidResource3 - ex:property "a" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-property ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:InvalidResource2 ; - sh:targetNode ex:InvalidResource3 ; - sh:targetNode ex:ValidResource1 ; - sh:targetNode ex:ValidResource2 ; -. -ex:TestShape-property - sh:path ex:property ; - sh:maxExclusive 1 ; -. -ex:ValidResource1 - ex:property 0 ; -. -ex:ValidResource2 - ex:property -1 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:maxExclusive 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:MaxExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape-property ; - sh:value 1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath ex:property ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape-property ; - sh:value 2 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource3 ; - sh:resultPath ex:property ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape-property ; - sh:value "a" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:property 1 ; +. +ex:InvalidResource2 + ex:property 2 ; +. +ex:InvalidResource3 + ex:property "a" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-property ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:InvalidResource2 ; + sh:targetNode ex:InvalidResource3 ; + sh:targetNode ex:ValidResource1 ; + sh:targetNode ex:ValidResource2 ; +. +ex:TestShape-property + sh:path ex:property ; + sh:maxExclusive 1 ; +. +ex:ValidResource1 + ex:property 0 ; +. +ex:ValidResource2 + ex:property -1 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:maxExclusive 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:MaxExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape-property ; + sh:value 1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath ex:property ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape-property ; + sh:value 2 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource3 ; + sh:resultPath ex:property ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape-property ; + sh:value "a" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/maxInclusive-001.ttl b/shacl12-test-suite/tests/core/property/maxInclusive-001.ttl index 2c5077f0..7d8bd856 100644 --- a/shacl12-test-suite/tests/core/property/maxInclusive-001.ttl +++ b/shacl12-test-suite/tests/core/property/maxInclusive-001.ttl @@ -1,71 +1,71 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:property 2 ; -. -ex:InvalidResource2 - ex:property "a" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-property ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:InvalidResource2 ; - sh:targetNode ex:ValidResource1 ; - sh:targetNode ex:ValidResource2 ; -. -ex:TestShape-property - sh:path ex:property ; - sh:maxInclusive 1 ; -. -ex:ValidResource1 - ex:property 0 ; -. -ex:ValidResource2 - ex:property 1 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:maxInclusive 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:MaxInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape-property ; - sh:value 2 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath ex:property ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; - sh:sourceShape ex:TestShape-property ; - sh:value "a" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:property 2 ; +. +ex:InvalidResource2 + ex:property "a" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-property ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:InvalidResource2 ; + sh:targetNode ex:ValidResource1 ; + sh:targetNode ex:ValidResource2 ; +. +ex:TestShape-property + sh:path ex:property ; + sh:maxInclusive 1 ; +. +ex:ValidResource1 + ex:property 0 ; +. +ex:ValidResource2 + ex:property 1 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:maxInclusive 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:MaxInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape-property ; + sh:value 2 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath ex:property ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxInclusiveConstraintComponent ; + sh:sourceShape ex:TestShape-property ; + sh:value "a" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/maxLength-001.ttl b/shacl12-test-suite/tests/core/property/maxLength-001.ttl index b6d4b48f..416e5fb4 100644 --- a/shacl12-test-suite/tests/core/property/maxLength-001.ttl +++ b/shacl12-test-suite/tests/core/property/maxLength-001.ttl @@ -1,61 +1,61 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:TestShape ; - ex:testProperty "ABC" ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-testProperty ; -. -ex:TestShape-testProperty - sh:path ex:testProperty ; - sh:datatype xsd:string ; - sh:maxLength 2 ; -. -ex:ValidInstance1 - rdf:type ex:TestShape ; - ex:testProperty "A" ; - ex:testProperty "AB" ; -. -ex:ValidInstance2 - rdf:type ex:TestShape ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:maxLength 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:InvalidInstance1 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - sh:value "ABC" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:TestShape ; + ex:testProperty "ABC" ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-testProperty ; +. +ex:TestShape-testProperty + sh:path ex:testProperty ; + sh:datatype xsd:string ; + sh:maxLength 2 ; +. +ex:ValidInstance1 + rdf:type ex:TestShape ; + ex:testProperty "A" ; + ex:testProperty "AB" ; +. +ex:ValidInstance2 + rdf:type ex:TestShape ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:maxLength 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:InvalidInstance1 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxLengthConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + sh:value "ABC" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/minCount-001.ttl b/shacl12-test-suite/tests/core/property/minCount-001.ttl index 680f9c4b..ad336e9e 100644 --- a/shacl12-test-suite/tests/core/property/minCount-001.ttl +++ b/shacl12-test-suite/tests/core/property/minCount-001.ttl @@ -1,62 +1,62 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidPerson - rdf:type ex:Person ; - rdfs:label "Invalid person" ; -. -ex:Person - rdf:type rdfs:Class ; - rdfs:label "Person" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:PersonShape - rdf:type sh:NodeShape ; - sh:property ex:PersonShape-firstName ; - sh:targetClass ex:Person ; - sh:targetNode ex:ValidResource ; -. -ex:PersonShape-firstName - sh:path ex:firstName ; - sh:datatype xsd:string ; - sh:minCount 1 ; -. -ex:ValidResource - rdf:type ex:Person ; - ex:firstName "John" ; - rdfs:label "Valid resource" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minCount 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:InvalidPerson ; - sh:resultPath ex:firstName ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinCountConstraintComponent ; - sh:sourceShape ex:PersonShape-firstName ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidPerson + rdf:type ex:Person ; + rdfs:label "Invalid person" ; +. +ex:Person + rdf:type rdfs:Class ; + rdfs:label "Person" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:PersonShape + rdf:type sh:NodeShape ; + sh:property ex:PersonShape-firstName ; + sh:targetClass ex:Person ; + sh:targetNode ex:ValidResource ; +. +ex:PersonShape-firstName + sh:path ex:firstName ; + sh:datatype xsd:string ; + sh:minCount 1 ; +. +ex:ValidResource + rdf:type ex:Person ; + ex:firstName "John" ; + rdfs:label "Valid resource" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minCount 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:InvalidPerson ; + sh:resultPath ex:firstName ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinCountConstraintComponent ; + sh:sourceShape ex:PersonShape-firstName ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/minCount-002.ttl b/shacl12-test-suite/tests/core/property/minCount-002.ttl index d4b4f13b..64bd30fc 100644 --- a/shacl12-test-suite/tests/core/property/minCount-002.ttl +++ b/shacl12-test-suite/tests/core/property/minCount-002.ttl @@ -1,41 +1,41 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:TestShape - rdf:type sh:NodeShape ; - sh:property [ - sh:path ex:property ; - sh:minCount 0 ; - sh:name "property" ; - ] ; - sh:targetNode ex:ValidResource1 ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minCount at property shape 001" ; - mf:action [ - sht:dataGraph <> ; - sht:shapesGraph <> ; - ] ; - mf:result [ - rdf:type sh:ValidationReport ; - sh:conforms "true"^^xsd:boolean ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:TestShape + rdf:type sh:NodeShape ; + sh:property [ + sh:path ex:property ; + sh:minCount 0 ; + sh:name "property" ; + ] ; + sh:targetNode ex:ValidResource1 ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minCount at property shape 001" ; + mf:action [ + sht:dataGraph <> ; + sht:shapesGraph <> ; + ] ; + mf:result [ + rdf:type sh:ValidationReport ; + sh:conforms "true"^^xsd:boolean ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/minExclusive-001.ttl b/shacl12-test-suite/tests/core/property/minExclusive-001.ttl index 8c99b43b..fe797e1d 100644 --- a/shacl12-test-suite/tests/core/property/minExclusive-001.ttl +++ b/shacl12-test-suite/tests/core/property/minExclusive-001.ttl @@ -1,69 +1,69 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:TestShape ; - ex:testProperty 40 ; -. -ex:InvalidInstance2 - rdf:type ex:TestShape ; - ex:testProperty 39 ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-testProperty ; -. -ex:TestShape-testProperty - sh:path ex:testProperty ; - sh:minExclusive 40 ; -. -ex:ValidInstance1 - rdf:type ex:TestShape ; - ex:testProperty 42 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minExclusive 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:InvalidInstance1 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - sh:value 40 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance2 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - sh:value 39 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:TestShape ; + ex:testProperty 40 ; +. +ex:InvalidInstance2 + rdf:type ex:TestShape ; + ex:testProperty 39 ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-testProperty ; +. +ex:TestShape-testProperty + sh:path ex:testProperty ; + sh:minExclusive 40 ; +. +ex:ValidInstance1 + rdf:type ex:TestShape ; + ex:testProperty 42 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minExclusive 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:InvalidInstance1 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + sh:value 40 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance2 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + sh:value 39 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/minExclusive-002.ttl b/shacl12-test-suite/tests/core/property/minExclusive-002.ttl index 2612e166..c9b8ff44 100644 --- a/shacl12-test-suite/tests/core/property/minExclusive-002.ttl +++ b/shacl12-test-suite/tests/core/property/minExclusive-002.ttl @@ -1,65 +1,65 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:TestShape ; - ex:testProperty "A string" ; -. -ex:InvalidInstance2 - rdf:type ex:TestShape ; - ex:testProperty rdfs:Resource ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-testProperty ; -. -ex:TestShape-testProperty - sh:path ex:testProperty ; - sh:minExclusive 40 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minExclusive at property shape 002" ; - 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:InvalidInstance1 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - sh:value "A string" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance2 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - sh:value rdfs:Resource ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:TestShape ; + ex:testProperty "A string" ; +. +ex:InvalidInstance2 + rdf:type ex:TestShape ; + ex:testProperty rdfs:Resource ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-testProperty ; +. +ex:TestShape-testProperty + sh:path ex:testProperty ; + sh:minExclusive 40 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minExclusive at property shape 002" ; + 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:InvalidInstance1 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + sh:value "A string" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance2 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinExclusiveConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + sh:value rdfs:Resource ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/minLength-001.ttl b/shacl12-test-suite/tests/core/property/minLength-001.ttl index 06f286e2..9fc511c5 100644 --- a/shacl12-test-suite/tests/core/property/minLength-001.ttl +++ b/shacl12-test-suite/tests/core/property/minLength-001.ttl @@ -1,61 +1,61 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:TestShape ; - ex:testProperty "A" ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-testProperty ; -. -ex:TestShape-testProperty - sh:path ex:testProperty ; - sh:datatype xsd:string ; - sh:minLength 2 ; -. -ex:ValidInstance1 - rdf:type ex:TestShape ; - ex:testProperty "AB" ; - ex:testProperty "ABC" ; -. -ex:ValidInstance2 - rdf:type ex:TestShape ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:minLength 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:InvalidInstance1 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - sh:value "A" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:TestShape ; + ex:testProperty "A" ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-testProperty ; +. +ex:TestShape-testProperty + sh:path ex:testProperty ; + sh:datatype xsd:string ; + sh:minLength 2 ; +. +ex:ValidInstance1 + rdf:type ex:TestShape ; + ex:testProperty "AB" ; + ex:testProperty "ABC" ; +. +ex:ValidInstance2 + rdf:type ex:TestShape ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:minLength 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:InvalidInstance1 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MinLengthConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + sh:value "A" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/node-001.ttl b/shacl12-test-suite/tests/core/property/node-001.ttl index 2245930b..dd2cfa96 100644 --- a/shacl12-test-suite/tests/core/property/node-001.ttl +++ b/shacl12-test-suite/tests/core/property/node-001.ttl @@ -1,113 +1,113 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Anon - rdf:type ex:Person ; - ex:firstName "Anon" ; -. -ex:Issue - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Issue" ; - rdfs:subClassOf rdfs:Resource ; - sh:property ex:Issue-assignedTo ; - sh:property ex:Issue-submittedBy ; -. -ex:Issue-assignedTo - sh:path ex:assignedTo ; - sh:class ex:Person ; - sh:node [ - rdfs:comment "All assignees must have an email and a last name." ; - sh:property [ - sh:path ex:email ; - sh:maxCount 1 ; - sh:minCount 1 ; - ] ; - sh:property [ - sh:path ex:lastName ; - sh:maxCount 1 ; - sh:minCount 1 ; - ] ; - ] ; -. -ex:Issue-submittedBy - sh:path ex:submittedBy ; - sh:class ex:Person ; - sh:minCount 1 ; -. -ex:Issue_1 - rdf:type ex:Issue ; - ex:assignedTo ex:Anon ; - ex:submittedBy ex:Anon ; - rdfs:label "Issue 1" ; -. -ex:Issue_2 - rdf:type ex:Issue ; - ex:assignedTo ex:JohnDoeWithEmail ; - ex:submittedBy ex:Anon ; - rdfs:label "Issue 2" ; -. -ex:JohnDoeWithEmail - rdf:type ex:Person ; - ex:email "john@doe.com" ; - ex:firstName "John" ; - ex:lastName "Doe" ; -. -ex:Person - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Person" ; - rdfs:subClassOf rdfs:Resource ; - sh:property [ - sh:path ex:email ; - ex:datatype xsd:string ; - rdfs:label "email" ; - ] ; - sh:property [ - sh:path ex:firstName ; - rdfs:label "first name" ; - sh:datatype xsd:string ; - sh:maxCount 1 ; - sh:minCount 1 ; - ] ; - sh:property [ - sh:path ex:lastName ; - rdfs:label "last name" ; - sh:datatype xsd:string ; - ] ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:node 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:Issue_1 ; - sh:resultPath ex:assignedTo ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeConstraintComponent ; - sh:sourceShape ex:Issue-assignedTo ; - sh:value ex:Anon ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Anon + rdf:type ex:Person ; + ex:firstName "Anon" ; +. +ex:Issue + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Issue" ; + rdfs:subClassOf rdfs:Resource ; + sh:property ex:Issue-assignedTo ; + sh:property ex:Issue-submittedBy ; +. +ex:Issue-assignedTo + sh:path ex:assignedTo ; + sh:class ex:Person ; + sh:node [ + rdfs:comment "All assignees must have an email and a last name." ; + sh:property [ + sh:path ex:email ; + sh:maxCount 1 ; + sh:minCount 1 ; + ] ; + sh:property [ + sh:path ex:lastName ; + sh:maxCount 1 ; + sh:minCount 1 ; + ] ; + ] ; +. +ex:Issue-submittedBy + sh:path ex:submittedBy ; + sh:class ex:Person ; + sh:minCount 1 ; +. +ex:Issue_1 + rdf:type ex:Issue ; + ex:assignedTo ex:Anon ; + ex:submittedBy ex:Anon ; + rdfs:label "Issue 1" ; +. +ex:Issue_2 + rdf:type ex:Issue ; + ex:assignedTo ex:JohnDoeWithEmail ; + ex:submittedBy ex:Anon ; + rdfs:label "Issue 2" ; +. +ex:JohnDoeWithEmail + rdf:type ex:Person ; + ex:email "john@doe.com" ; + ex:firstName "John" ; + ex:lastName "Doe" ; +. +ex:Person + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Person" ; + rdfs:subClassOf rdfs:Resource ; + sh:property [ + sh:path ex:email ; + ex:datatype xsd:string ; + rdfs:label "email" ; + ] ; + sh:property [ + sh:path ex:firstName ; + rdfs:label "first name" ; + sh:datatype xsd:string ; + sh:maxCount 1 ; + sh:minCount 1 ; + ] ; + sh:property [ + sh:path ex:lastName ; + rdfs:label "last name" ; + sh:datatype xsd:string ; + ] ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:node 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:Issue_1 ; + sh:resultPath ex:assignedTo ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeConstraintComponent ; + sh:sourceShape ex:Issue-assignedTo ; + sh:value ex:Anon ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/node-002.ttl b/shacl12-test-suite/tests/core/property/node-002.ttl index f028f57f..adc141ad 100644 --- a/shacl12-test-suite/tests/core/property/node-002.ttl +++ b/shacl12-test-suite/tests/core/property/node-002.ttl @@ -1,75 +1,75 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:AddressShape - rdf:type sh:NodeShape ; - sh:property ex:AddressShape-postalCode ; -. -ex:AddressShape-postalCode - sh:path ex:postalCode ; - sh:datatype xsd:string ; - sh:maxCount 1 ; -. -ex:Bob - rdf:type ex:Person ; - ex:address ex:BobsAddress ; -. -ex:BobsAddress - ex:postalCode "1234" ; -. -ex:Person - rdf:type rdfs:Class ; - rdfs:label "Person" ; -. -ex:PersonShape - rdf:type sh:NodeShape ; - sh:property ex:PersonShape-address ; - sh:targetClass ex:Person ; -. -ex:PersonShape-address - sh:path ex:address ; - sh:minCount 1 ; - sh:node ex:AddressShape ; -. -ex:Reto - rdf:type ex:Person ; - ex:address ex:RetosAddress ; -. -ex:RetosAddress - ex:postalCode 5678 ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:node at property shape 002" ; - 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:Reto ; - sh:resultPath ex:address ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeConstraintComponent ; - sh:sourceShape ex:PersonShape-address ; - sh:value ex:RetosAddress ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:AddressShape + rdf:type sh:NodeShape ; + sh:property ex:AddressShape-postalCode ; +. +ex:AddressShape-postalCode + sh:path ex:postalCode ; + sh:datatype xsd:string ; + sh:maxCount 1 ; +. +ex:Bob + rdf:type ex:Person ; + ex:address ex:BobsAddress ; +. +ex:BobsAddress + ex:postalCode "1234" ; +. +ex:Person + rdf:type rdfs:Class ; + rdfs:label "Person" ; +. +ex:PersonShape + rdf:type sh:NodeShape ; + sh:property ex:PersonShape-address ; + sh:targetClass ex:Person ; +. +ex:PersonShape-address + sh:path ex:address ; + sh:minCount 1 ; + sh:node ex:AddressShape ; +. +ex:Reto + rdf:type ex:Person ; + ex:address ex:RetosAddress ; +. +ex:RetosAddress + ex:postalCode 5678 ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:node at property shape 002" ; + 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:Reto ; + sh:resultPath ex:address ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeConstraintComponent ; + sh:sourceShape ex:PersonShape-address ; + sh:value ex:RetosAddress ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/nodeKind-001.ttl b/shacl12-test-suite/tests/core/property/nodeKind-001.ttl index d40515d0..35addd15 100644 --- a/shacl12-test-suite/tests/core/property/nodeKind-001.ttl +++ b/shacl12-test-suite/tests/core/property/nodeKind-001.ttl @@ -1,371 +1,371 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InstanceWithBlankNode - rdf:type ex:MyClass ; - ex:myProperty _:b55454 ; -. -ex:InstanceWithBlankNodeAndIRI - rdf:type ex:MyClass ; - ex:myProperty rdfs:Class ; - ex:myProperty _:b67098 ; -. -ex:InstanceWithBlankNodeAndLiteral - rdf:type ex:MyClass ; - ex:myProperty "Literal" ; - ex:myProperty _:b99026 ; -. -ex:InstanceWithIRI - rdf:type ex:MyClass ; - ex:myProperty rdfs:Class ; -. -ex:InstanceWithIRIAndLiteral - rdf:type ex:MyClass ; - ex:myProperty rdfs:Class ; - ex:myProperty "Literal" ; -. -ex:InstanceWithLiteral - rdf:type ex:MyClass ; - ex:myProperty "Literal" ; -. -ex:MyClass - rdf:type rdfs:Class ; - rdfs:label "My class" ; -. -ex:ShapeWithBlankNode - rdf:type sh:NodeShape ; - sh:property _:b38619 ; - sh:targetClass ex:MyClass ; -. -ex:ShapeWithBlankNodeOrIRI - rdf:type sh:NodeShape ; - sh:property _:b3078 ; - sh:targetClass ex:MyClass ; -. -ex:ShapeWithBlankNodeOrLiteral - rdf:type sh:NodeShape ; - sh:property _:b14975 ; - sh:targetClass ex:MyClass ; -. -ex:ShapeWithIRI - rdf:type sh:NodeShape ; - sh:property _:b97614 ; - sh:targetClass ex:MyClass ; -. -ex:ShapeWithIRIOrLiteral - rdf:type sh:NodeShape ; - sh:property _:b97860 ; - sh:targetClass ex:MyClass ; -. -ex:ShapeWithLiteral - rdf:type sh:NodeShape ; - sh:property _:b79526 ; - sh:targetClass ex:MyClass ; -. -ex:myProperty - rdf:type rdf:Property ; - rdfs:domain ex:MyClass ; - rdfs:label "my property" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:nodeKind 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:InstanceWithBlankNode ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b79526 ; - sh:value _:b55454 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNode ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b97614 ; - sh:value _:b55454 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNode ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b97860 ; - sh:value _:b55454 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndIRI ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b14975 ; - sh:value rdfs:Class ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndIRI ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b38619 ; - sh:value rdfs:Class ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndIRI ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b79526 ; - sh:value rdfs:Class ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndIRI ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b79526 ; - sh:value _:b67098 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndIRI ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b97614 ; - sh:value _:b67098 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndIRI ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b97860 ; - sh:value _:b67098 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b3078 ; - sh:value "Literal" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b38619 ; - sh:value "Literal" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b79526 ; - sh:value _:b99026 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b97614 ; - sh:value "Literal" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b97614 ; - sh:value _:b99026 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b97860 ; - sh:value _:b99026 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithIRI ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b14975 ; - sh:value rdfs:Class ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithIRI ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b38619 ; - sh:value rdfs:Class ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithIRI ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b79526 ; - sh:value rdfs:Class ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithIRIAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b3078 ; - sh:value "Literal" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithIRIAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b14975 ; - sh:value rdfs:Class ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithIRIAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b38619 ; - sh:value rdfs:Class ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithIRIAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b38619 ; - sh:value "Literal" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithIRIAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b79526 ; - sh:value rdfs:Class ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithIRIAndLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b97614 ; - sh:value "Literal" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b3078 ; - sh:value "Literal" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b38619 ; - sh:value "Literal" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InstanceWithLiteral ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; - sh:sourceShape _:b97614 ; - sh:value "Literal" ; - ] ; - ] ; - mf:status sht:approved ; -. -_:b3078 - sh:path ex:myProperty ; - sh:nodeKind sh:BlankNodeOrIRI ; -. -_:b14975 - sh:path ex:myProperty ; - sh:nodeKind sh:BlankNodeOrLiteral ; -. -_:b38619 - sh:path ex:myProperty ; - sh:nodeKind sh:BlankNode ; -. -_:b55454 - rdf:type rdfs:Resource ; -. -_:b67098 - rdf:type rdfs:Resource ; -. -_:b79526 - sh:path ex:myProperty ; - sh:nodeKind sh:Literal ; -. -_:b97614 - sh:path ex:myProperty ; - sh:nodeKind sh:IRI ; -. -_:b97860 - sh:path ex:myProperty ; - sh:nodeKind sh:IRIOrLiteral ; -. -_:b99026 - rdf:type rdfs:Resource ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InstanceWithBlankNode + rdf:type ex:MyClass ; + ex:myProperty _:b55454 ; +. +ex:InstanceWithBlankNodeAndIRI + rdf:type ex:MyClass ; + ex:myProperty rdfs:Class ; + ex:myProperty _:b67098 ; +. +ex:InstanceWithBlankNodeAndLiteral + rdf:type ex:MyClass ; + ex:myProperty "Literal" ; + ex:myProperty _:b99026 ; +. +ex:InstanceWithIRI + rdf:type ex:MyClass ; + ex:myProperty rdfs:Class ; +. +ex:InstanceWithIRIAndLiteral + rdf:type ex:MyClass ; + ex:myProperty rdfs:Class ; + ex:myProperty "Literal" ; +. +ex:InstanceWithLiteral + rdf:type ex:MyClass ; + ex:myProperty "Literal" ; +. +ex:MyClass + rdf:type rdfs:Class ; + rdfs:label "My class" ; +. +ex:ShapeWithBlankNode + rdf:type sh:NodeShape ; + sh:property _:b38619 ; + sh:targetClass ex:MyClass ; +. +ex:ShapeWithBlankNodeOrIRI + rdf:type sh:NodeShape ; + sh:property _:b3078 ; + sh:targetClass ex:MyClass ; +. +ex:ShapeWithBlankNodeOrLiteral + rdf:type sh:NodeShape ; + sh:property _:b14975 ; + sh:targetClass ex:MyClass ; +. +ex:ShapeWithIRI + rdf:type sh:NodeShape ; + sh:property _:b97614 ; + sh:targetClass ex:MyClass ; +. +ex:ShapeWithIRIOrLiteral + rdf:type sh:NodeShape ; + sh:property _:b97860 ; + sh:targetClass ex:MyClass ; +. +ex:ShapeWithLiteral + rdf:type sh:NodeShape ; + sh:property _:b79526 ; + sh:targetClass ex:MyClass ; +. +ex:myProperty + rdf:type rdf:Property ; + rdfs:domain ex:MyClass ; + rdfs:label "my property" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:nodeKind 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:InstanceWithBlankNode ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b79526 ; + sh:value _:b55454 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNode ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b97614 ; + sh:value _:b55454 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNode ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b97860 ; + sh:value _:b55454 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndIRI ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b14975 ; + sh:value rdfs:Class ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndIRI ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b38619 ; + sh:value rdfs:Class ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndIRI ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b79526 ; + sh:value rdfs:Class ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndIRI ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b79526 ; + sh:value _:b67098 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndIRI ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b97614 ; + sh:value _:b67098 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndIRI ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b97860 ; + sh:value _:b67098 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b3078 ; + sh:value "Literal" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b38619 ; + sh:value "Literal" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b79526 ; + sh:value _:b99026 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b97614 ; + sh:value "Literal" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b97614 ; + sh:value _:b99026 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithBlankNodeAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b97860 ; + sh:value _:b99026 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithIRI ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b14975 ; + sh:value rdfs:Class ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithIRI ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b38619 ; + sh:value rdfs:Class ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithIRI ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b79526 ; + sh:value rdfs:Class ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithIRIAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b3078 ; + sh:value "Literal" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithIRIAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b14975 ; + sh:value rdfs:Class ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithIRIAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b38619 ; + sh:value rdfs:Class ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithIRIAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b38619 ; + sh:value "Literal" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithIRIAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b79526 ; + sh:value rdfs:Class ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithIRIAndLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b97614 ; + sh:value "Literal" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b3078 ; + sh:value "Literal" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b38619 ; + sh:value "Literal" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InstanceWithLiteral ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:NodeKindConstraintComponent ; + sh:sourceShape _:b97614 ; + sh:value "Literal" ; + ] ; + ] ; + mf:status sht:approved ; +. +_:b3078 + sh:path ex:myProperty ; + sh:nodeKind sh:BlankNodeOrIRI ; +. +_:b14975 + sh:path ex:myProperty ; + sh:nodeKind sh:BlankNodeOrLiteral ; +. +_:b38619 + sh:path ex:myProperty ; + sh:nodeKind sh:BlankNode ; +. +_:b55454 + rdf:type rdfs:Resource ; +. +_:b67098 + rdf:type rdfs:Resource ; +. +_:b79526 + sh:path ex:myProperty ; + sh:nodeKind sh:Literal ; +. +_:b97614 + sh:path ex:myProperty ; + sh:nodeKind sh:IRI ; +. +_:b97860 + sh:path ex:myProperty ; + sh:nodeKind sh:IRIOrLiteral ; +. +_:b99026 + rdf:type rdfs:Resource ; +. diff --git a/shacl12-test-suite/tests/core/property/not-001.ttl b/shacl12-test-suite/tests/core/property/not-001.ttl index bad0e6fb..f681bd94 100644 --- a/shacl12-test-suite/tests/core/property/not-001.ttl +++ b/shacl12-test-suite/tests/core/property/not-001.ttl @@ -1,68 +1,68 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -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 ( - - ) ; -. - - 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 ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +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 ( + + ) ; +. + + 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 ; +. diff --git a/shacl12-test-suite/tests/core/property/or-001.ttl b/shacl12-test-suite/tests/core/property/or-001.ttl index 323ed0f5..d2ad5bdd 100644 --- a/shacl12-test-suite/tests/core/property/or-001.ttl +++ b/shacl12-test-suite/tests/core/property/or-001.ttl @@ -1,76 +1,76 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Address - rdf:type rdfs:Class ; - rdfs:label "Address" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:AddressShape - rdf:type sh:NodeShape ; - rdfs:label "Address shape" ; - sh:property ex:AddressShape-address ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:ValidResource1 ; - sh:targetNode ex:ValidResource2 ; -. -ex:AddressShape-address - sh:path ex:address ; - sh:or ( - [ - sh:datatype xsd:string ; - ] - [ - sh:class ex:Address ; - ] - ) ; -. -ex:InvalidResource1 - rdf:type rdfs:Resource ; - ex:address "true"^^xsd:boolean ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; - ex:address "Home" ; -. -ex:ValidResource2 - rdf:type rdfs:Resource ; - ex:address [ - rdf:type ex:Address ; - ] ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:or 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:address ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:OrConstraintComponent ; - sh:sourceShape ex:AddressShape-address ; - sh:value "true"^^xsd:boolean ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Address + rdf:type rdfs:Class ; + rdfs:label "Address" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:AddressShape + rdf:type sh:NodeShape ; + rdfs:label "Address shape" ; + sh:property ex:AddressShape-address ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:ValidResource1 ; + sh:targetNode ex:ValidResource2 ; +. +ex:AddressShape-address + sh:path ex:address ; + sh:or ( + [ + sh:datatype xsd:string ; + ] + [ + sh:class ex:Address ; + ] + ) ; +. +ex:InvalidResource1 + rdf:type rdfs:Resource ; + ex:address "true"^^xsd:boolean ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; + ex:address "Home" ; +. +ex:ValidResource2 + rdf:type rdfs:Resource ; + ex:address [ + rdf:type ex:Address ; + ] ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:or 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:address ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:OrConstraintComponent ; + sh:sourceShape ex:AddressShape-address ; + sh:value "true"^^xsd:boolean ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/or-datatypes-001.ttl b/shacl12-test-suite/tests/core/property/or-datatypes-001.ttl index dc59b420..8e8f0a12 100644 --- a/shacl12-test-suite/tests/core/property/or-datatypes-001.ttl +++ b/shacl12-test-suite/tests/core/property/or-datatypes-001.ttl @@ -1,95 +1,95 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - rdf:type rdfs:Resource ; - rdfs:comment owl:Thing ; - rdfs:comment 42 ; - rdfs:comment "A string" ; - rdfs:comment "none"^^xsd:boolean ; - rdfs:label "Invalid resource1" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-comment ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:ValidResource1 ; -. -ex:TestShape-comment - sh:path rdfs:comment ; - sh:or ( - [ - sh:datatype xsd:string ; - ] - [ - sh:datatype rdf:HTML ; - ] - [ - sh:datatype rdf:langString ; - ] - [ - sh:datatype xsd:boolean ; - ] - ) ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; - rdfs:comment "
HTML
"^^rdf:HTML ; - rdfs:comment "A language string"@en ; - rdfs:comment "A string" ; - rdfs:label "Valid resource1" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:or of sh:datatypes 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 rdfs:comment ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:OrConstraintComponent ; - sh:sourceShape ex:TestShape-comment ; - sh:value owl:Thing ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource1 ; - sh:resultPath rdfs:comment ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:OrConstraintComponent ; - sh:sourceShape ex:TestShape-comment ; - sh:value 42 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource1 ; - sh:resultPath rdfs:comment ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:OrConstraintComponent ; - sh:sourceShape ex:TestShape-comment ; - sh:value "none"^^xsd:boolean ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + rdf:type rdfs:Resource ; + rdfs:comment owl:Thing ; + rdfs:comment 42 ; + rdfs:comment "A string" ; + rdfs:comment "none"^^xsd:boolean ; + rdfs:label "Invalid resource1" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-comment ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:ValidResource1 ; +. +ex:TestShape-comment + sh:path rdfs:comment ; + sh:or ( + [ + sh:datatype xsd:string ; + ] + [ + sh:datatype rdf:HTML ; + ] + [ + sh:datatype rdf:langString ; + ] + [ + sh:datatype xsd:boolean ; + ] + ) ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; + rdfs:comment "
HTML
"^^rdf:HTML ; + rdfs:comment "A language string"@en ; + rdfs:comment "A string" ; + rdfs:label "Valid resource1" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:or of sh:datatypes 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 rdfs:comment ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:OrConstraintComponent ; + sh:sourceShape ex:TestShape-comment ; + sh:value owl:Thing ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource1 ; + sh:resultPath rdfs:comment ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:OrConstraintComponent ; + sh:sourceShape ex:TestShape-comment ; + sh:value 42 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource1 ; + sh:resultPath rdfs:comment ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:OrConstraintComponent ; + sh:sourceShape ex:TestShape-comment ; + sh:value "none"^^xsd:boolean ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/pattern-001.ttl b/shacl12-test-suite/tests/core/property/pattern-001.ttl index 2c63ad80..096e4863 100644 --- a/shacl12-test-suite/tests/core/property/pattern-001.ttl +++ b/shacl12-test-suite/tests/core/property/pattern-001.ttl @@ -1,74 +1,74 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:TestShape ; - ex:property "Maria" ; - rdfs:label "Invalid instance1" ; -. -ex:InvalidInstance2 - rdf:type ex:TestShape ; - ex:property "john" ; - rdfs:label "Invalid instance2" ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-property ; -. -ex:TestShape-property - sh:path ex:property ; - sh:datatype xsd:string ; - sh:pattern "Joh" ; -. -ex:ValidInstance1 - rdf:type ex:TestShape ; - ex:property "Hi Joh" ; - ex:property "John" ; - rdfs:label "Valid instance1" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:pattern 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:InvalidInstance1 ; - sh:resultPath ex:property ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:PatternConstraintComponent ; - sh:sourceShape ex:TestShape-property ; - sh:value "Maria" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance2 ; - sh:resultPath ex:property ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:PatternConstraintComponent ; - sh:sourceShape ex:TestShape-property ; - sh:value "john" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:TestShape ; + ex:property "Maria" ; + rdfs:label "Invalid instance1" ; +. +ex:InvalidInstance2 + rdf:type ex:TestShape ; + ex:property "john" ; + rdfs:label "Invalid instance2" ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-property ; +. +ex:TestShape-property + sh:path ex:property ; + sh:datatype xsd:string ; + sh:pattern "Joh" ; +. +ex:ValidInstance1 + rdf:type ex:TestShape ; + ex:property "Hi Joh" ; + ex:property "John" ; + rdfs:label "Valid instance1" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:pattern 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:InvalidInstance1 ; + sh:resultPath ex:property ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:PatternConstraintComponent ; + sh:sourceShape ex:TestShape-property ; + sh:value "Maria" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance2 ; + sh:resultPath ex:property ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:PatternConstraintComponent ; + sh:sourceShape ex:TestShape-property ; + sh:value "john" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/pattern-002.ttl b/shacl12-test-suite/tests/core/property/pattern-002.ttl index 498c2a3a..568f7664 100644 --- a/shacl12-test-suite/tests/core/property/pattern-002.ttl +++ b/shacl12-test-suite/tests/core/property/pattern-002.ttl @@ -1,66 +1,66 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:TestShape ; - ex:property "Maria" ; - rdfs:label "Invalid instance1" ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-property ; -. -ex:TestShape-property - sh:path ex:property ; - rdfs:label "property" ; - sh:datatype xsd:string ; - sh:flags "i" ; - sh:pattern "joh" ; -. -ex:ValidInstance1 - rdf:type ex:TestShape ; - ex:property "Hi Joh" ; - ex:property "John" ; - rdfs:label "Valid instance1" ; -. -ex:ValidInstance2 - rdf:type ex:TestShape ; - ex:property "john" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:pattern at property shape 002" ; - 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:InvalidInstance1 ; - sh:resultPath ex:property ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:PatternConstraintComponent ; - sh:sourceShape ex:TestShape-property ; - sh:value "Maria" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:TestShape ; + ex:property "Maria" ; + rdfs:label "Invalid instance1" ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-property ; +. +ex:TestShape-property + sh:path ex:property ; + rdfs:label "property" ; + sh:datatype xsd:string ; + sh:flags "i" ; + sh:pattern "joh" ; +. +ex:ValidInstance1 + rdf:type ex:TestShape ; + ex:property "Hi Joh" ; + ex:property "John" ; + rdfs:label "Valid instance1" ; +. +ex:ValidInstance2 + rdf:type ex:TestShape ; + ex:property "john" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:pattern at property shape 002" ; + 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:InvalidInstance1 ; + sh:resultPath ex:property ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:PatternConstraintComponent ; + sh:sourceShape ex:TestShape-property ; + sh:value "Maria" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/property-001.ttl b/shacl12-test-suite/tests/core/property/property-001.ttl index cd7bfd42..dcfb76c1 100644 --- a/shacl12-test-suite/tests/core/property/property-001.ttl +++ b/shacl12-test-suite/tests/core/property/property-001.ttl @@ -1,100 +1,100 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Address - rdf:type rdfs:Class ; - rdfs:label "Address" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:City - rdf:type rdfs:Class ; - rdfs:label "City" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:InvalidAddress - rdf:type ex:Address ; - ex:city ex:InvalidCity ; -. -ex:InvalidPerson1 - rdf:type ex:Person ; - ex:address ex:InvalidAddress ; -. -ex:InvalidPerson2 - rdf:type ex:Person ; - ex:address ex:InvalidAddress ; - ex:address ex:ValidAddress ; -. -ex:Person - rdf:type rdfs:Class ; - rdfs:label "Person" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:PersonShape - rdf:type sh:NodeShape ; - rdfs:label "Person shape" ; - sh:property [ - sh:path ex:address ; - sh:property ex:PersonShape-address-city ; - ] ; - sh:targetClass ex:Person ; -. -ex:PersonShape-address-city - sh:path ex:city ; - sh:class ex:City ; -. -ex:ProperCity - rdf:type ex:City ; - rdfs:label "Proper city" ; -. -ex:ValidAddress - rdf:type ex:Address ; - ex:city ex:ProperCity ; -. -ex:ValidPerson1 - rdf:type ex:Person ; - ex:address ex:ValidAddress ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:property 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:InvalidAddress ; - sh:resultPath ex:city ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:PersonShape-address-city ; - sh:value ex:InvalidCity ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidAddress ; - sh:resultPath ex:city ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:ClassConstraintComponent ; - sh:sourceShape ex:PersonShape-address-city ; - sh:value ex:InvalidCity ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Address + rdf:type rdfs:Class ; + rdfs:label "Address" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:City + rdf:type rdfs:Class ; + rdfs:label "City" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:InvalidAddress + rdf:type ex:Address ; + ex:city ex:InvalidCity ; +. +ex:InvalidPerson1 + rdf:type ex:Person ; + ex:address ex:InvalidAddress ; +. +ex:InvalidPerson2 + rdf:type ex:Person ; + ex:address ex:InvalidAddress ; + ex:address ex:ValidAddress ; +. +ex:Person + rdf:type rdfs:Class ; + rdfs:label "Person" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:PersonShape + rdf:type sh:NodeShape ; + rdfs:label "Person shape" ; + sh:property [ + sh:path ex:address ; + sh:property ex:PersonShape-address-city ; + ] ; + sh:targetClass ex:Person ; +. +ex:PersonShape-address-city + sh:path ex:city ; + sh:class ex:City ; +. +ex:ProperCity + rdf:type ex:City ; + rdfs:label "Proper city" ; +. +ex:ValidAddress + rdf:type ex:Address ; + ex:city ex:ProperCity ; +. +ex:ValidPerson1 + rdf:type ex:Person ; + ex:address ex:ValidAddress ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:property 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:InvalidAddress ; + sh:resultPath ex:city ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:PersonShape-address-city ; + sh:value ex:InvalidCity ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidAddress ; + sh:resultPath ex:city ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:ClassConstraintComponent ; + sh:sourceShape ex:PersonShape-address-city ; + sh:value ex:InvalidCity ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/qualifiedMinCountDisjoint-001.ttl b/shacl12-test-suite/tests/core/property/qualifiedMinCountDisjoint-001.ttl index 00d91c24..a44a86c4 100644 --- a/shacl12-test-suite/tests/core/property/qualifiedMinCountDisjoint-001.ttl +++ b/shacl12-test-suite/tests/core/property/qualifiedMinCountDisjoint-001.ttl @@ -1,116 +1,116 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Digit - rdf:type rdfs:Class ; - rdfs:label "Digit" ; -. -ex:Finger - rdf:type rdfs:Class ; - rdfs:label "Finger" ; - rdfs:subClassOf ex:Digit ; -. -ex:FingerAndThumb - rdf:type ex:Finger ; - rdf:type ex:Thumb ; - rdfs:label "Finger and thumb" ; -. -ex:FingerShape - rdf:type sh:NodeShape ; - rdfs:label "Finger shape" ; - sh:class ex:Finger ; -. -ex:Finger_1 - rdf:type ex:Finger ; - rdfs:label "Finger 1" ; -. -ex:Hand - rdf:type rdfs:Class ; - rdfs:label "Hand" ; -. -ex:HandShape - rdf:type sh:NodeShape ; - rdfs:label "Hand shape" ; - sh:property ex:HandShape-digit-maxCount4 ; - sh:property ex:HandShape-digit-minCount1 ; - sh:targetClass ex:Hand ; -. -ex:HandShape-digit-maxCount4 - rdf:type sh:PropertyShape ; - sh:path ex:digit ; - sh:qualifiedMaxCount 4 ; - sh:qualifiedValueShape ex:FingerShape ; - sh:qualifiedValueShapesDisjoint "true"^^xsd:boolean ; -. -ex:HandShape-digit-minCount1 - rdf:type sh:PropertyShape ; - sh:path ex:digit ; - sh:qualifiedMinCount 1 ; - sh:qualifiedValueShape ex:ThumbShape ; - sh:qualifiedValueShapesDisjoint "true"^^xsd:boolean ; -. -ex:InvalidHand1 - rdf:type ex:Hand ; - ex:digit ex:FingerAndThumb ; - rdfs:label "Invalid hand1" ; -. -ex:Thumb - rdf:type rdfs:Class ; - rdfs:label "Thumb" ; - rdfs:subClassOf ex:Digit ; -. -ex:ThumbShape - rdf:type sh:NodeShape ; - rdfs:label "Thumb shape" ; - sh:class ex:Thumb ; -. -ex:Thumb_1 - rdf:type ex:Thumb ; - rdfs:label "Thumb 1" ; -. -ex:ValidHand1 - rdf:type ex:Hand ; - ex:digit ex:Finger_1 ; - ex:digit ex:Thumb_1 ; - rdfs:label "Valid hand1" ; -. -ex:digit - rdf:type rdf:Property ; - rdfs:domain ex:Hand ; - rdfs:label "digit" ; - rdfs:range ex:Digit ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:qualifiedMinCount with disjoint shapes 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:InvalidHand1 ; - sh:resultPath ex:digit ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:QualifiedMinCountConstraintComponent ; - sh:sourceShape ex:HandShape-digit-minCount1 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Digit + rdf:type rdfs:Class ; + rdfs:label "Digit" ; +. +ex:Finger + rdf:type rdfs:Class ; + rdfs:label "Finger" ; + rdfs:subClassOf ex:Digit ; +. +ex:FingerAndThumb + rdf:type ex:Finger ; + rdf:type ex:Thumb ; + rdfs:label "Finger and thumb" ; +. +ex:FingerShape + rdf:type sh:NodeShape ; + rdfs:label "Finger shape" ; + sh:class ex:Finger ; +. +ex:Finger_1 + rdf:type ex:Finger ; + rdfs:label "Finger 1" ; +. +ex:Hand + rdf:type rdfs:Class ; + rdfs:label "Hand" ; +. +ex:HandShape + rdf:type sh:NodeShape ; + rdfs:label "Hand shape" ; + sh:property ex:HandShape-digit-maxCount4 ; + sh:property ex:HandShape-digit-minCount1 ; + sh:targetClass ex:Hand ; +. +ex:HandShape-digit-maxCount4 + rdf:type sh:PropertyShape ; + sh:path ex:digit ; + sh:qualifiedMaxCount 4 ; + sh:qualifiedValueShape ex:FingerShape ; + sh:qualifiedValueShapesDisjoint "true"^^xsd:boolean ; +. +ex:HandShape-digit-minCount1 + rdf:type sh:PropertyShape ; + sh:path ex:digit ; + sh:qualifiedMinCount 1 ; + sh:qualifiedValueShape ex:ThumbShape ; + sh:qualifiedValueShapesDisjoint "true"^^xsd:boolean ; +. +ex:InvalidHand1 + rdf:type ex:Hand ; + ex:digit ex:FingerAndThumb ; + rdfs:label "Invalid hand1" ; +. +ex:Thumb + rdf:type rdfs:Class ; + rdfs:label "Thumb" ; + rdfs:subClassOf ex:Digit ; +. +ex:ThumbShape + rdf:type sh:NodeShape ; + rdfs:label "Thumb shape" ; + sh:class ex:Thumb ; +. +ex:Thumb_1 + rdf:type ex:Thumb ; + rdfs:label "Thumb 1" ; +. +ex:ValidHand1 + rdf:type ex:Hand ; + ex:digit ex:Finger_1 ; + ex:digit ex:Thumb_1 ; + rdfs:label "Valid hand1" ; +. +ex:digit + rdf:type rdf:Property ; + rdfs:domain ex:Hand ; + rdfs:label "digit" ; + rdfs:range ex:Digit ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:qualifiedMinCount with disjoint shapes 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:InvalidHand1 ; + sh:resultPath ex:digit ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:QualifiedMinCountConstraintComponent ; + sh:sourceShape ex:HandShape-digit-minCount1 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/qualifiedValueShape-001.ttl b/shacl12-test-suite/tests/core/property/qualifiedValueShape-001.ttl index ead8f719..65e88c1c 100644 --- a/shacl12-test-suite/tests/core/property/qualifiedValueShape-001.ttl +++ b/shacl12-test-suite/tests/core/property/qualifiedValueShape-001.ttl @@ -1,80 +1,80 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:APGARObservationShape - rdf:type sh:NodeShape ; - sh:property ex:APGARObservationShape-related ; - sh:targetNode ex:Observation1 ; -. -ex:APGARObservationShape-related - sh:path ex:related ; - sh:qualifiedMaxCount 3 ; - sh:qualifiedMinCount 3 ; - sh:qualifiedValueShape [ - sh:property [ - sh:path ex:related_target ; - sh:node [ - sh:property [ - sh:path ex:reference ; - sh:hasValue ex:something ; - ] ; - ] ; - ] ; - ] ; -. -ex:Observation1 - rdf:type ex:Observation ; - ex:related [ - ex:related_target [ - ex:reference ex:something ; - ] ; - ex:related_type "has-component"^^ex:code ; - ] ; - ex:related [ - ex:related_target [ - ex:reference ex:something ; - ] ; - ex:related_type "has-component"^^ex:code ; - ] ; - ex:related [ - ex:related_target [ - ex:reference ex:unrelated ; - ] ; - ex:related_type "has-component"^^ex:code ; - ] ; - sh:nodeShape ex:APGARObservationShape ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:qualifiedValueShape 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:Observation1 ; - sh:resultPath ex:related ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:QualifiedMinCountConstraintComponent ; - sh:sourceShape ex:APGARObservationShape-related ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:APGARObservationShape + rdf:type sh:NodeShape ; + sh:property ex:APGARObservationShape-related ; + sh:targetNode ex:Observation1 ; +. +ex:APGARObservationShape-related + sh:path ex:related ; + sh:qualifiedMaxCount 3 ; + sh:qualifiedMinCount 3 ; + sh:qualifiedValueShape [ + sh:property [ + sh:path ex:related_target ; + sh:node [ + sh:property [ + sh:path ex:reference ; + sh:hasValue ex:something ; + ] ; + ] ; + ] ; + ] ; +. +ex:Observation1 + rdf:type ex:Observation ; + ex:related [ + ex:related_target [ + ex:reference ex:something ; + ] ; + ex:related_type "has-component"^^ex:code ; + ] ; + ex:related [ + ex:related_target [ + ex:reference ex:something ; + ] ; + ex:related_type "has-component"^^ex:code ; + ] ; + ex:related [ + ex:related_target [ + ex:reference ex:unrelated ; + ] ; + ex:related_type "has-component"^^ex:code ; + ] ; + sh:nodeShape ex:APGARObservationShape ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:qualifiedValueShape 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:Observation1 ; + sh:resultPath ex:related ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:QualifiedMinCountConstraintComponent ; + sh:sourceShape ex:APGARObservationShape-related ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/qualifiedValueShapesDisjoint-001.ttl b/shacl12-test-suite/tests/core/property/qualifiedValueShapesDisjoint-001.ttl index 1cc8cbc1..9711c6a9 100644 --- a/shacl12-test-suite/tests/core/property/qualifiedValueShapesDisjoint-001.ttl +++ b/shacl12-test-suite/tests/core/property/qualifiedValueShapesDisjoint-001.ttl @@ -1,128 +1,128 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Finger - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Finger" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:Finger1 - rdf:type ex:Finger ; - rdfs:label "Finger1" ; -. -ex:Finger2 - rdf:type ex:Finger ; - rdfs:label "Finger2" ; -. -ex:Finger3 - rdf:type ex:Finger ; - rdfs:label "Finger3" ; -. -ex:Finger4 - rdf:type ex:Finger ; - rdfs:label "Finger4" ; -. -ex:FingerAndThumb - rdf:type ex:Finger ; - rdf:type ex:Thumb ; - rdfs:label "Finger and thumb" ; -. -ex:Hand - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Hand" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:HandShape - rdf:type sh:NodeShape ; - sh:property ex:HandShape-digit1 ; - sh:property ex:HandShape-digit4 ; - sh:targetClass ex:Hand ; -. -ex:HandShape-digit1 - sh:path ex:digit ; - sh:qualifiedMaxCount 1 ; - sh:qualifiedMinCount 1 ; - sh:qualifiedValueShape [ - sh:class ex:Thumb ; - ] ; - sh:qualifiedValueShapesDisjoint "true"^^xsd:boolean ; -. -ex:HandShape-digit4 - sh:path ex:digit ; - sh:qualifiedMaxCount 4 ; - sh:qualifiedMinCount 4 ; - sh:qualifiedValueShape [ - sh:class ex:Finger ; - ] ; - sh:qualifiedValueShapesDisjoint "true"^^xsd:boolean ; -. -ex:InvalidHand1 - rdf:type ex:Hand ; - ex:digit ex:Finger1 ; - ex:digit ex:Finger2 ; - ex:digit ex:Finger3 ; - ex:digit ex:FingerAndThumb ; -. -ex:Thumb - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Thumb" ; - rdfs:subClassOf rdfs:Resource ; -. -ex:Thumb1 - rdf:type ex:Thumb ; - rdfs:label "Thumb1" ; -. -ex:ValidHand - rdf:type ex:Hand ; - ex:digit ex:Finger1 ; - ex:digit ex:Finger2 ; - ex:digit ex:Finger3 ; - ex:digit ex:Finger4 ; - ex:digit ex:Thumb1 ; - rdfs:label "Valid hand" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:qualifiedValueShapesDisjoint 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:InvalidHand1 ; - sh:resultPath ex:digit ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:QualifiedMinCountConstraintComponent ; - sh:sourceShape ex:HandShape-digit1 ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidHand1 ; - sh:resultPath ex:digit ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:QualifiedMinCountConstraintComponent ; - sh:sourceShape ex:HandShape-digit4 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Finger + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Finger" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:Finger1 + rdf:type ex:Finger ; + rdfs:label "Finger1" ; +. +ex:Finger2 + rdf:type ex:Finger ; + rdfs:label "Finger2" ; +. +ex:Finger3 + rdf:type ex:Finger ; + rdfs:label "Finger3" ; +. +ex:Finger4 + rdf:type ex:Finger ; + rdfs:label "Finger4" ; +. +ex:FingerAndThumb + rdf:type ex:Finger ; + rdf:type ex:Thumb ; + rdfs:label "Finger and thumb" ; +. +ex:Hand + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Hand" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:HandShape + rdf:type sh:NodeShape ; + sh:property ex:HandShape-digit1 ; + sh:property ex:HandShape-digit4 ; + sh:targetClass ex:Hand ; +. +ex:HandShape-digit1 + sh:path ex:digit ; + sh:qualifiedMaxCount 1 ; + sh:qualifiedMinCount 1 ; + sh:qualifiedValueShape [ + sh:class ex:Thumb ; + ] ; + sh:qualifiedValueShapesDisjoint "true"^^xsd:boolean ; +. +ex:HandShape-digit4 + sh:path ex:digit ; + sh:qualifiedMaxCount 4 ; + sh:qualifiedMinCount 4 ; + sh:qualifiedValueShape [ + sh:class ex:Finger ; + ] ; + sh:qualifiedValueShapesDisjoint "true"^^xsd:boolean ; +. +ex:InvalidHand1 + rdf:type ex:Hand ; + ex:digit ex:Finger1 ; + ex:digit ex:Finger2 ; + ex:digit ex:Finger3 ; + ex:digit ex:FingerAndThumb ; +. +ex:Thumb + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Thumb" ; + rdfs:subClassOf rdfs:Resource ; +. +ex:Thumb1 + rdf:type ex:Thumb ; + rdfs:label "Thumb1" ; +. +ex:ValidHand + rdf:type ex:Hand ; + ex:digit ex:Finger1 ; + ex:digit ex:Finger2 ; + ex:digit ex:Finger3 ; + ex:digit ex:Finger4 ; + ex:digit ex:Thumb1 ; + rdfs:label "Valid hand" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:qualifiedValueShapesDisjoint 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:InvalidHand1 ; + sh:resultPath ex:digit ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:QualifiedMinCountConstraintComponent ; + sh:sourceShape ex:HandShape-digit1 ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidHand1 ; + sh:resultPath ex:digit ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:QualifiedMinCountConstraintComponent ; + sh:sourceShape ex:HandShape-digit4 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/singleLine-001.ttl b/shacl12-test-suite/tests/core/property/singleLine-001.ttl index 4e59c57c..35b2a9c3 100644 --- a/shacl12-test-suite/tests/core/property/singleLine-001.ttl +++ b/shacl12-test-suite/tests/core/property/singleLine-001.ttl @@ -1,105 +1,105 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstanceF - rdf:type ex:SingleLineExampleShape ; - rdfs:label "Invalid\finstanceF" ; -. -ex:InvalidInstanceN - rdf:type ex:SingleLineExampleShape ; - rdfs:label "Invalid\ninstanceN" ; -. -ex:InvalidInstanceR - rdf:type ex:SingleLineExampleShape ; - rdfs:label "Invalid\rinstanceR" ; -. -ex:InvalidInstanceV - rdf:type ex:SingleLineExampleShape ; - rdfs:label "Invalid\u000BinstanceV" ; -. -ex:SingleLineExampleShape - a sh:NodeShape, rdfs:Class ; - sh:property ex:SingleLineExampleShape-label ; - sh:property ex:SingleLineExampleShape-comment ; -. -ex:SingleLineExampleShape-label - a sh:PropertyShape ; - sh:path rdfs:label ; - sh:datatype xsd:string ; - sh:singleLine true ; -. -ex:SingleLineExampleShape-comment - a sh:PropertyShape ; - sh:path rdfs:comment ; - sh:or ( [ sh:datatype xsd:string ] [ sh:datatype rdf:langString ] ) ; - sh:singleLine false ; -. -ex:ValidInstance1 - rdf:type ex:SingleLineExampleShape ; - rdfs:label "Valid instance1" ; - rdfs:comment """This is a multi- -line comment. -""" -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:singleLine 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:InvalidInstanceF ; - sh:resultPath rdfs:label ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:SingleLineConstraintComponent ; - sh:sourceShape ex:SingleLineExampleShape-label ; - sh:value "Invalid\finstanceF" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstanceN ; - sh:resultPath rdfs:label ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:SingleLineConstraintComponent ; - sh:sourceShape ex:SingleLineExampleShape-label ; - sh:value "Invalid\ninstanceN" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstanceR ; - sh:resultPath rdfs:label ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:SingleLineConstraintComponent ; - sh:sourceShape ex:SingleLineExampleShape-label ; - sh:value "Invalid\rinstanceR" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstanceV ; - sh:resultPath rdfs:label ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:SingleLineConstraintComponent ; - sh:sourceShape ex:SingleLineExampleShape-label ; - sh:value "Invalid\u000BinstanceV" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstanceF + rdf:type ex:SingleLineExampleShape ; + rdfs:label "Invalid\finstanceF" ; +. +ex:InvalidInstanceN + rdf:type ex:SingleLineExampleShape ; + rdfs:label "Invalid\ninstanceN" ; +. +ex:InvalidInstanceR + rdf:type ex:SingleLineExampleShape ; + rdfs:label "Invalid\rinstanceR" ; +. +ex:InvalidInstanceV + rdf:type ex:SingleLineExampleShape ; + rdfs:label "Invalid\u000BinstanceV" ; +. +ex:SingleLineExampleShape + a sh:NodeShape, rdfs:Class ; + sh:property ex:SingleLineExampleShape-label ; + sh:property ex:SingleLineExampleShape-comment ; +. +ex:SingleLineExampleShape-label + a sh:PropertyShape ; + sh:path rdfs:label ; + sh:datatype xsd:string ; + sh:singleLine true ; +. +ex:SingleLineExampleShape-comment + a sh:PropertyShape ; + sh:path rdfs:comment ; + sh:or ( [ sh:datatype xsd:string ] [ sh:datatype rdf:langString ] ) ; + sh:singleLine false ; +. +ex:ValidInstance1 + rdf:type ex:SingleLineExampleShape ; + rdfs:label "Valid instance1" ; + rdfs:comment """This is a multi- +line comment. +""" +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:singleLine 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:InvalidInstanceF ; + sh:resultPath rdfs:label ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:SingleLineConstraintComponent ; + sh:sourceShape ex:SingleLineExampleShape-label ; + sh:value "Invalid\finstanceF" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstanceN ; + sh:resultPath rdfs:label ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:SingleLineConstraintComponent ; + sh:sourceShape ex:SingleLineExampleShape-label ; + sh:value "Invalid\ninstanceN" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstanceR ; + sh:resultPath rdfs:label ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:SingleLineConstraintComponent ; + sh:sourceShape ex:SingleLineExampleShape-label ; + sh:value "Invalid\rinstanceR" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstanceV ; + sh:resultPath rdfs:label ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:SingleLineConstraintComponent ; + sh:sourceShape ex:SingleLineExampleShape-label ; + sh:value "Invalid\u000BinstanceV" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/uniqueLang-001.ttl b/shacl12-test-suite/tests/core/property/uniqueLang-001.ttl index ffec0ff0..fdc2e5a2 100644 --- a/shacl12-test-suite/tests/core/property/uniqueLang-001.ttl +++ b/shacl12-test-suite/tests/core/property/uniqueLang-001.ttl @@ -1,86 +1,86 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:TestShape ; - ex:testProperty "Me" ; - ex:testProperty "Me"@en ; - ex:testProperty "Moi"@fr ; - ex:testProperty "Myself"@en ; -. -ex:InvalidInstance2 - rdf:type ex:TestShape ; - ex:testProperty "I"@en ; - ex:testProperty "Ich"@de ; - ex:testProperty "Me"@en ; - ex:testProperty "Mich"@de ; - ex:testProperty "Myself"@en ; -. -ex:TestShape - rdf:type rdfs:Class ; - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-testProperty ; -. -ex:TestShape-testProperty - sh:path ex:testProperty ; - rdfs:label "test property" ; - sh:uniqueLang "true"^^xsd:boolean ; -. -ex:ValidInstance1 - rdf:type ex:TestShape ; - ex:testProperty "Me" ; - ex:testProperty "Me"@en ; - ex:testProperty "Moi"@fr ; - ex:testProperty "Myself" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:uniqueLang 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:InvalidInstance1 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:UniqueLangConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance2 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:UniqueLangConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance2 ; - sh:resultPath ex:testProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:UniqueLangConstraintComponent ; - sh:sourceShape ex:TestShape-testProperty ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:TestShape ; + ex:testProperty "Me" ; + ex:testProperty "Me"@en ; + ex:testProperty "Moi"@fr ; + ex:testProperty "Myself"@en ; +. +ex:InvalidInstance2 + rdf:type ex:TestShape ; + ex:testProperty "I"@en ; + ex:testProperty "Ich"@de ; + ex:testProperty "Me"@en ; + ex:testProperty "Mich"@de ; + ex:testProperty "Myself"@en ; +. +ex:TestShape + rdf:type rdfs:Class ; + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-testProperty ; +. +ex:TestShape-testProperty + sh:path ex:testProperty ; + rdfs:label "test property" ; + sh:uniqueLang "true"^^xsd:boolean ; +. +ex:ValidInstance1 + rdf:type ex:TestShape ; + ex:testProperty "Me" ; + ex:testProperty "Me"@en ; + ex:testProperty "Moi"@fr ; + ex:testProperty "Myself" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:uniqueLang 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:InvalidInstance1 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:UniqueLangConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance2 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:UniqueLangConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance2 ; + sh:resultPath ex:testProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:UniqueLangConstraintComponent ; + sh:sourceShape ex:TestShape-testProperty ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/property/uniqueLang-002-data.ttl b/shacl12-test-suite/tests/core/property/uniqueLang-002-data.ttl index 4db2738e..6227d592 100644 --- a/shacl12-test-suite/tests/core/property/uniqueLang-002-data.ttl +++ b/shacl12-test-suite/tests/core/property/uniqueLang-002-data.ttl @@ -1,3 +1,3 @@ -@prefix ex: . +@prefix ex: . ex:i ex:message "HI"@en, "Hi"@en . diff --git a/shacl12-test-suite/tests/core/property/uniqueLang-002-shapes.ttl b/shacl12-test-suite/tests/core/property/uniqueLang-002-shapes.ttl index 648d4821..9d64694d 100644 --- a/shacl12-test-suite/tests/core/property/uniqueLang-002-shapes.ttl +++ b/shacl12-test-suite/tests/core/property/uniqueLang-002-shapes.ttl @@ -1,5 +1,5 @@ @prefix sh: . -@prefix ex: . +@prefix ex: . @prefix xsd: . ex:s1 a sh:PropertyShape ; diff --git a/shacl12-test-suite/tests/core/property/uniqueLang-002.ttl b/shacl12-test-suite/tests/core/property/uniqueLang-002.ttl index c1b1f3bb..4c11ec88 100644 --- a/shacl12-test-suite/tests/core/property/uniqueLang-002.ttl +++ b/shacl12-test-suite/tests/core/property/uniqueLang-002.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/targets/multipleTargets-001.ttl b/shacl12-test-suite/tests/core/targets/multipleTargets-001.ttl index 81a99e81..3dbe393a 100644 --- a/shacl12-test-suite/tests/core/targets/multipleTargets-001.ttl +++ b/shacl12-test-suite/tests/core/targets/multipleTargets-001.ttl @@ -1,56 +1,56 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:property1 "Also a value" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:in ( - ex:ValidResource1 - ex:ValidResource2 - ) ; - sh:targetSubjectsOf ex:property1 ; - sh:targetSubjectsOf ex:property2 ; -. -ex:ValidResource1 - ex:property1 "Some value" ; -. -ex:ValidResource2 - ex:property2 "Other value" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of multiple targets 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:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:InConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource1 ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:property1 "Also a value" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:in ( + ex:ValidResource1 + ex:ValidResource2 + ) ; + sh:targetSubjectsOf ex:property1 ; + sh:targetSubjectsOf ex:property2 ; +. +ex:ValidResource1 + ex:property1 "Some value" ; +. +ex:ValidResource2 + ex:property2 "Other value" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of multiple targets 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:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:InConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource1 ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/targets/targetClass-001.ttl b/shacl12-test-suite/tests/core/targets/targetClass-001.ttl index e1d5a55c..a3d05455 100644 --- a/shacl12-test-suite/tests/core/targets/targetClass-001.ttl +++ b/shacl12-test-suite/tests/core/targets/targetClass-001.ttl @@ -1,62 +1,62 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:MyClass ; - ex:myProperty "A" ; - ex:myProperty "B" ; -. -ex:MyClass - rdf:type rdfs:Class ; -. -ex:MyShape - rdf:type sh:NodeShape ; - sh:property ex:MyShape-myProperty ; - sh:targetClass ex:MyClass ; -. -ex:MyShape-myProperty - sh:path ex:myProperty ; - sh:maxCount 1 ; -. -ex:ValidInstance1 - rdf:type ex:MyClass ; - ex:myProperty "A" ; -. -ex:ValidInstance2 - ex:myProperty "A" ; - ex:myProperty "B" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:targetClass 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:InvalidInstance1 ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape ex:MyShape-myProperty ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:MyClass ; + ex:myProperty "A" ; + ex:myProperty "B" ; +. +ex:MyClass + rdf:type rdfs:Class ; +. +ex:MyShape + rdf:type sh:NodeShape ; + sh:property ex:MyShape-myProperty ; + sh:targetClass ex:MyClass ; +. +ex:MyShape-myProperty + sh:path ex:myProperty ; + sh:maxCount 1 ; +. +ex:ValidInstance1 + rdf:type ex:MyClass ; + ex:myProperty "A" ; +. +ex:ValidInstance2 + ex:myProperty "A" ; + ex:myProperty "B" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:targetClass 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:InvalidInstance1 ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape ex:MyShape-myProperty ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/targets/targetClassImplicit-001.ttl b/shacl12-test-suite/tests/core/targets/targetClassImplicit-001.ttl index 05cafccb..80f14a4c 100644 --- a/shacl12-test-suite/tests/core/targets/targetClassImplicit-001.ttl +++ b/shacl12-test-suite/tests/core/targets/targetClassImplicit-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/targets/targetClassImplicit-002.ttl b/shacl12-test-suite/tests/core/targets/targetClassImplicit-002.ttl index 98fd7711..68c9bb65 100644 --- a/shacl12-test-suite/tests/core/targets/targetClassImplicit-002.ttl +++ b/shacl12-test-suite/tests/core/targets/targetClassImplicit-002.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/core/targets/targetNode-001.ttl b/shacl12-test-suite/tests/core/targets/targetNode-001.ttl index 195e3ffc..96ab4b11 100644 --- a/shacl12-test-suite/tests/core/targets/targetNode-001.ttl +++ b/shacl12-test-suite/tests/core/targets/targetNode-001.ttl @@ -1,57 +1,57 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - rdf:type rdfs:Resource ; - rdfs:label "Invalid resource 1" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:property ex:TestShape-label ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:ValidResource1 ; -. -ex:TestShape-label - sh:path rdfs:label ; - rdfs:label "label" ; - sh:datatype xsd:string ; - sh:maxCount 0 ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:targetNode 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 rdfs:label ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape ex:TestShape-label ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + rdf:type rdfs:Resource ; + rdfs:label "Invalid resource 1" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:property ex:TestShape-label ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:ValidResource1 ; +. +ex:TestShape-label + sh:path rdfs:label ; + rdfs:label "label" ; + sh:datatype xsd:string ; + sh:maxCount 0 ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:targetNode 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 rdfs:label ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape ex:TestShape-label ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/targets/targetObjectsOf-001.ttl b/shacl12-test-suite/tests/core/targets/targetObjectsOf-001.ttl index 09eeea65..c0c4196d 100644 --- a/shacl12-test-suite/tests/core/targets/targetObjectsOf-001.ttl +++ b/shacl12-test-suite/tests/core/targets/targetObjectsOf-001.ttl @@ -1,65 +1,65 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - ex:testProperty "String" ; -. -ex:InvalidResource2 - ex:testProperty rdfs:Resource ; -. -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:datatype xsd:integer ; - sh:targetObjectsOf ex:testProperty ; -. -ex:ValidResource1 - ex:testProperty 100 ; - ex:testProperty 42 ; -. -ex:testProperty - rdf:type rdf:Property ; - rdfs:label "test property" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:targetObjectsOf 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 rdfs:Resource ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value rdfs:Resource ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode "String" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "String" ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + ex:testProperty "String" ; +. +ex:InvalidResource2 + ex:testProperty rdfs:Resource ; +. +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:datatype xsd:integer ; + sh:targetObjectsOf ex:testProperty ; +. +ex:ValidResource1 + ex:testProperty 100 ; + ex:testProperty 42 ; +. +ex:testProperty + rdf:type rdf:Property ; + rdfs:label "test property" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:targetObjectsOf 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 rdfs:Resource ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value rdfs:Resource ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode "String" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:DatatypeConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "String" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/targets/targetSubjectsOf-001.ttl b/shacl12-test-suite/tests/core/targets/targetSubjectsOf-001.ttl index 9069f17b..f0b6b7b6 100644 --- a/shacl12-test-suite/tests/core/targets/targetSubjectsOf-001.ttl +++ b/shacl12-test-suite/tests/core/targets/targetSubjectsOf-001.ttl @@ -1,57 +1,57 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - ex:myProperty "A" ; - ex:myProperty "B" ; -. -ex:MyClass - rdf:type rdfs:Class ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-myProperty ; - sh:targetSubjectsOf ex:myProperty ; -. -ex:TestShape-myProperty - rdf:type sh:PropertyShape ; - sh:path ex:myProperty ; - sh:maxCount 1 ; -. -ex:ValidInstance1 - ex:myProperty "A" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:targetSubjectsOf 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:InvalidInstance1 ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape ex:TestShape-myProperty ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + ex:myProperty "A" ; + ex:myProperty "B" ; +. +ex:MyClass + rdf:type rdfs:Class ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-myProperty ; + sh:targetSubjectsOf ex:myProperty ; +. +ex:TestShape-myProperty + rdf:type sh:PropertyShape ; + sh:path ex:myProperty ; + sh:maxCount 1 ; +. +ex:ValidInstance1 + ex:myProperty "A" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:targetSubjectsOf 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:InvalidInstance1 ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape ex:TestShape-myProperty ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/targets/targetSubjectsOf-002.ttl b/shacl12-test-suite/tests/core/targets/targetSubjectsOf-002.ttl index e4adacdc..e3fbcd60 100644 --- a/shacl12-test-suite/tests/core/targets/targetSubjectsOf-002.ttl +++ b/shacl12-test-suite/tests/core/targets/targetSubjectsOf-002.ttl @@ -1,74 +1,74 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidInstance1 - rdf:type ex:MyClass ; - ex:myProperty "A" ; - ex:myProperty "B" ; -. -ex:InvalidInstance2 - ex:myProperty "A" ; - ex:myProperty "B" ; -. -ex:MyClass - rdf:type rdfs:Class ; -. -ex:TestShape - rdf:type sh:NodeShape ; - sh:property ex:TestShape-myProperty ; - sh:targetClass ex:MyClass ; - sh:targetSubjectsOf ex:myProperty ; -. -ex:TestShape-myProperty - sh:path ex:myProperty ; - sh:maxCount 1 ; -. -ex:ValidInstance1 - rdf:type ex:MyClass ; - ex:myProperty "A" ; -. -ex:ValidInstance2 - ex:myProperty "A" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:targetSubjectsOf 002" ; - 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:InvalidInstance1 ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape ex:TestShape-myProperty ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidInstance2 ; - sh:resultPath ex:myProperty ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape ex:TestShape-myProperty ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidInstance1 + rdf:type ex:MyClass ; + ex:myProperty "A" ; + ex:myProperty "B" ; +. +ex:InvalidInstance2 + ex:myProperty "A" ; + ex:myProperty "B" ; +. +ex:MyClass + rdf:type rdfs:Class ; +. +ex:TestShape + rdf:type sh:NodeShape ; + sh:property ex:TestShape-myProperty ; + sh:targetClass ex:MyClass ; + sh:targetSubjectsOf ex:myProperty ; +. +ex:TestShape-myProperty + sh:path ex:myProperty ; + sh:maxCount 1 ; +. +ex:ValidInstance1 + rdf:type ex:MyClass ; + ex:myProperty "A" ; +. +ex:ValidInstance2 + ex:myProperty "A" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:targetSubjectsOf 002" ; + 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:InvalidInstance1 ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape ex:TestShape-myProperty ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidInstance2 ; + sh:resultPath ex:myProperty ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape ex:TestShape-myProperty ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/core/validation-reports/shared-data.ttl b/shacl12-test-suite/tests/core/validation-reports/shared-data.ttl index 5263a71c..485a2502 100644 --- a/shacl12-test-suite/tests/core/validation-reports/shared-data.ttl +++ b/shacl12-test-suite/tests/core/validation-reports/shared-data.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . ex:i ex:p ex:j . ex:i ex:q ex:j . ex:j ex:r ex:k . diff --git a/shacl12-test-suite/tests/core/validation-reports/shared-shapes.ttl b/shacl12-test-suite/tests/core/validation-reports/shared-shapes.ttl index 26f4b731..2e82bf45 100644 --- a/shacl12-test-suite/tests/core/validation-reports/shared-shapes.ttl +++ b/shacl12-test-suite/tests/core/validation-reports/shared-shapes.ttl @@ -1,5 +1,5 @@ @prefix sh: . -@prefix ex: . +@prefix ex: . ex:s1 a sh:NodeShape ; sh:targetNode ex:i ; diff --git a/shacl12-test-suite/tests/core/validation-reports/shared.ttl b/shacl12-test-suite/tests/core/validation-reports/shared.ttl index ae4b01ca..4b5df292 100644 --- a/shacl12-test-suite/tests/core/validation-reports/shared.ttl +++ b/shacl12-test-suite/tests/core/validation-reports/shared.ttl @@ -6,7 +6,7 @@ @prefix sht: . @prefix xsd: . -@prefix ex: . +@prefix ex: . # This test case is under discussion, as there are different interpretations # on whether the nested sh:property constraint that is reached twice should diff --git a/shacl12-test-suite/tests/sparql/component/nodeValidator-001.ttl b/shacl12-test-suite/tests/sparql/component/nodeValidator-001.ttl index 1bcabc45..fa7f30f3 100644 --- a/shacl12-test-suite/tests/sparql/component/nodeValidator-001.ttl +++ b/shacl12-test-suite/tests/sparql/component/nodeValidator-001.ttl @@ -1,83 +1,83 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - - - sh:declare [ - rdf:type sh:PrefixDeclaration ; - sh:namespace "http://datashapes.org/sh/tests/sparql/component/nodeValidator-001.test#"^^xsd:anyURI ; - sh:prefix "ex" ; - ] ; -. -ex:InvalidResource1 - ex:property "Other" ; -. -ex:TestConstraintComponent - rdf:type sh:ConstraintComponent ; - rdfs:label "Test constraint component" ; - sh:nodeValidator [ - rdf:type sh:SPARQLSelectValidator ; - sh:select """ - SELECT DISTINCT $this - WHERE { - $this ?p ?o . - FILTER NOT EXISTS { - $this ex:property ?requiredParam . - }}""" ; - sh:prefixes ; - ] ; - sh:parameter [ - sh:path ex:optionalParam ; - sh:datatype xsd:integer ; - sh:name "optional param" ; - sh:optional "true"^^xsd:boolean ; - ] ; - sh:parameter [ - sh:path ex:requiredParam ; - sh:datatype xsd:string ; - sh:name "required param" ; - ] ; -. -ex:TestShape - rdf:type sh:NodeShape ; - ex:requiredParam "Value" ; - rdfs:label "Test shape" ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:ValidResource1 ; -. -ex:ValidResource1 - ex:property "Value" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:nodeValidator 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:resultSeverity sh:Violation ; - sh:sourceConstraintComponent ex:TestConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource1 ; - ] ; - ] ; - mf:status sht:proposed ; +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + + + sh:declare [ + rdf:type sh:PrefixDeclaration ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + sh:prefix "ex" ; + ] ; +. +ex:InvalidResource1 + ex:property "Other" ; +. +ex:TestConstraintComponent + rdf:type sh:ConstraintComponent ; + rdfs:label "Test constraint component" ; + sh:nodeValidator [ + rdf:type sh:SPARQLSelectValidator ; + sh:select """ + SELECT DISTINCT $this + WHERE { + $this ?p ?o . + FILTER NOT EXISTS { + $this ex:property ?requiredParam . + }}""" ; + sh:prefixes ; + ] ; + sh:parameter [ + sh:path ex:optionalParam ; + sh:datatype xsd:integer ; + sh:name "optional param" ; + sh:optional "true"^^xsd:boolean ; + ] ; + sh:parameter [ + sh:path ex:requiredParam ; + sh:datatype xsd:string ; + sh:name "required param" ; + ] ; +. +ex:TestShape + rdf:type sh:NodeShape ; + ex:requiredParam "Value" ; + rdfs:label "Test shape" ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:ValidResource1 ; +. +ex:ValidResource1 + ex:property "Value" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:nodeValidator 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:resultSeverity sh:Violation ; + sh:sourceConstraintComponent ex:TestConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource1 ; + ] ; + ] ; + mf:status sht:proposed ; . \ No newline at end of file diff --git a/shacl12-test-suite/tests/sparql/component/optional-001.ttl b/shacl12-test-suite/tests/sparql/component/optional-001.ttl index 0f3ba1f8..23fbace2 100644 --- a/shacl12-test-suite/tests/sparql/component/optional-001.ttl +++ b/shacl12-test-suite/tests/sparql/component/optional-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . @@ -11,7 +11,7 @@ sh:declare [ rdf:type sh:PrefixDeclaration ; - sh:namespace "http://datashapes.org/sh/tests/sparql/component/optional-001.test#"^^xsd:anyURI ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; sh:prefix "ex" ; ] ; . diff --git a/shacl12-test-suite/tests/sparql/component/propertyValidator-select-001.ttl b/shacl12-test-suite/tests/sparql/component/propertyValidator-select-001.ttl index a501c542..94a88bf7 100644 --- a/shacl12-test-suite/tests/sparql/component/propertyValidator-select-001.ttl +++ b/shacl12-test-suite/tests/sparql/component/propertyValidator-select-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/sparql/component/validator-001.ttl b/shacl12-test-suite/tests/sparql/component/validator-001.ttl index 67b9d94a..533fb372 100644 --- a/shacl12-test-suite/tests/sparql/component/validator-001.ttl +++ b/shacl12-test-suite/tests/sparql/component/validator-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/sparql/node/prefixes-001.ttl b/shacl12-test-suite/tests/sparql/node/prefixes-001.ttl index de29d1f6..2a40ecce 100644 --- a/shacl12-test-suite/tests/sparql/node/prefixes-001.ttl +++ b/shacl12-test-suite/tests/sparql/node/prefixes-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . @@ -11,7 +11,7 @@ sh:declare [ rdf:type sh:PrefixDeclaration ; - sh:namespace "http://datashapes.org/sh/tests/sparql/node/prefixes-001.test#"^^xsd:anyURI ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; sh:prefix "ex" ; ] ; . diff --git a/shacl12-test-suite/tests/sparql/node/sparql-001.ttl b/shacl12-test-suite/tests/sparql/node/sparql-001.ttl index eae95ebc..455260e3 100644 --- a/shacl12-test-suite/tests/sparql/node/sparql-001.ttl +++ b/shacl12-test-suite/tests/sparql/node/sparql-001.ttl @@ -1,89 +1,89 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:InvalidResource1 - rdf:type rdfs:Resource ; - rdfs:label "Invalid resource 1" ; -. -ex:InvalidResource2 - rdf:type rdfs:Resource ; - rdfs:label "Invalid label 1" ; - rdfs:label "Invalid label 2" ; -. -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:sparql ex:TestShape-sparql ; - sh:targetNode ex:InvalidResource1 ; - sh:targetNode ex:InvalidResource2 ; - sh:targetNode ex:ValidResource1 ; -. -ex:TestShape-sparql - sh:message "Cannot have a label" ; - sh:prefixes ; +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:InvalidResource1 + rdf:type rdfs:Resource ; + rdfs:label "Invalid resource 1" ; +. +ex:InvalidResource2 + rdf:type rdfs:Resource ; + rdfs:label "Invalid label 1" ; + rdfs:label "Invalid label 2" ; +. +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:sparql ex:TestShape-sparql ; + sh:targetNode ex:InvalidResource1 ; + sh:targetNode ex:InvalidResource2 ; + sh:targetNode ex:ValidResource1 ; +. +ex:TestShape-sparql + sh:message "Cannot have a label" ; + sh:prefixes ; sh:select """ SELECT $this ?path ?value WHERE { $this ?path ?value . FILTER (?path = ) . - }""" ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:sparql at node 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 rdfs:label ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint ex:TestShape-sparql ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Invalid resource 1" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath rdfs:label ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint ex:TestShape-sparql ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Invalid label 1" ; - ] ; - sh:result [ - rdf:type sh:ValidationResult ; - sh:focusNode ex:InvalidResource2 ; - sh:resultPath rdfs:label ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint ex:TestShape-sparql ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value "Invalid label 2" ; - ] ; - ] ; - mf:status sht:approved ; -. + }""" ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:sparql at node 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 rdfs:label ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraint ex:TestShape-sparql ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Invalid resource 1" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath rdfs:label ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraint ex:TestShape-sparql ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Invalid label 1" ; + ] ; + sh:result [ + rdf:type sh:ValidationResult ; + sh:focusNode ex:InvalidResource2 ; + sh:resultPath rdfs:label ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraint ex:TestShape-sparql ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value "Invalid label 2" ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/node/sparql-002.ttl b/shacl12-test-suite/tests/sparql/node/sparql-002.ttl index e6dd7c11..d58ec16c 100644 --- a/shacl12-test-suite/tests/sparql/node/sparql-002.ttl +++ b/shacl12-test-suite/tests/sparql/node/sparql-002.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . @@ -11,7 +11,7 @@ sh:declare [ rdf:type sh:PrefixDeclaration ; - sh:namespace "http://datashapes.org/sh/tests/sparql/node/sparql-002.test#"^^xsd:anyURI ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; sh:prefix "ex" ; ] ; . diff --git a/shacl12-test-suite/tests/sparql/node/sparql-003.ttl b/shacl12-test-suite/tests/sparql/node/sparql-003.ttl index 2c603e1a..01ddaa16 100644 --- a/shacl12-test-suite/tests/sparql/node/sparql-003.ttl +++ b/shacl12-test-suite/tests/sparql/node/sparql-003.ttl @@ -1,70 +1,70 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - - - sh:declare [ - rdf:type sh:PrefixDeclaration ; - sh:namespace "http://datashapes.org/sh/tests/sparql/node/sparql-003.test#"^^xsd:anyURI ; - sh:prefix "ex" ; - ] ; -. -ex:InvalidCountry - rdf:type ex:Country ; - ex:germanLabel "Spain"@en ; -. -ex:LanguageExampleShape - rdf:type sh:NodeShape ; - rdf:type sh:SPARQLConstraint ; - sh:message "Values are literals with German language tag." ; - sh:prefixes ; +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + + + sh:declare [ + rdf:type sh:PrefixDeclaration ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + sh:prefix "ex" ; + ] ; +. +ex:InvalidCountry + rdf:type ex:Country ; + ex:germanLabel "Spain"@en ; +. +ex:LanguageExampleShape + rdf:type sh:NodeShape ; + rdf:type sh:SPARQLConstraint ; + sh:message "Values are literals with German language tag." ; + sh:prefixes ; sh:select """ SELECT $this (ex:germanLabel AS ?path) WHERE { $this ex:germanLabel ?value . FILTER (!isLiteral(?value) || !langMatches(lang(?value), \"de\")) } - """ ; - sh:severity sh:Warning ; - sh:sparql ex:LanguageExampleShape ; - sh:targetClass ex:Country ; -. -ex:ValidCountry - rdf:type ex:Country ; - ex:germanLabel "Spanien"@de ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:sparql at node shape 003" ; - 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:InvalidCountry ; - sh:resultPath ex:germanLabel ; - sh:resultSeverity sh:Warning ; - sh:sourceConstraint ex:LanguageExampleShape ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:LanguageExampleShape ; - sh:value ex:InvalidCountry ; - ] ; - ] ; - mf:status sht:approved ; -. + """ ; + sh:severity sh:Warning ; + sh:sparql ex:LanguageExampleShape ; + sh:targetClass ex:Country ; +. +ex:ValidCountry + rdf:type ex:Country ; + ex:germanLabel "Spanien"@de ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:sparql at node shape 003" ; + 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:InvalidCountry ; + sh:resultPath ex:germanLabel ; + sh:resultSeverity sh:Warning ; + sh:sourceConstraint ex:LanguageExampleShape ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:LanguageExampleShape ; + sh:value ex:InvalidCountry ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-001.ttl b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-001.ttl index cf902754..8218c4a9 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-001.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-001.ttl @@ -1,63 +1,63 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex: - sh:declare [ - sh:prefix "ex" ; - sh:namespace "http://datashapes.org/sh/tests/sparql/pre-binding/pre-binding-001.test#"^^xsd:anyURI ; - ] . - -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:sparql ex:TestShape-sparql ; - sh:targetNode ex:InvalidResource ; -. -ex:TestShape-sparql - sh:message "Test message" ; - sh:prefixes ex: ; +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex: + sh:declare [ + sh:prefix "ex" ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + ] . + +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:sparql ex:TestShape-sparql ; + sh:targetNode ex:InvalidResource ; +. +ex:TestShape-sparql + sh:message "Test message" ; + sh:prefixes ex: ; sh:select """ SELECT $this WHERE { FILTER ($this = ex:InvalidResource) . - }""" ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of pre-binding in FILTER" ; - 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:InvalidResource ; - sh:resultMessage "Test message" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint ex:TestShape-sparql ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource ; - ] ; - ] ; - mf:status sht:approved ; -. + }""" ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of pre-binding in FILTER" ; + 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:InvalidResource ; + sh:resultMessage "Test message" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraint ex:TestShape-sparql ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-002.ttl b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-002.ttl index 819b6816..f6ccf9be 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-002.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-002.ttl @@ -1,67 +1,67 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex: - sh:declare [ - sh:prefix "ex" ; - sh:namespace "http://datashapes.org/sh/tests/sparql/pre-binding/pre-binding-002.test#"^^xsd:anyURI ; - ] . - -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:sparql ex:TestShape-sparql ; - sh:targetNode ex:InvalidResource ; -. -ex:TestShape-sparql - sh:prefixes ex: ; +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex: + sh:declare [ + sh:prefix "ex" ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + ] . + +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:sparql ex:TestShape-sparql ; + sh:targetNode ex:InvalidResource ; +. +ex:TestShape-sparql + sh:prefixes ex: ; sh:select """ SELECT $this - WHERE { - { - FILTER (false) . - } - UNION + WHERE { { - FILTER ($this = ex:InvalidResource) . + FILTER (false) . } - }""" ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of pre-binding in UNION" ; - 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:InvalidResource ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint ex:TestShape-sparql ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource ; - ] ; - ] ; - mf:status sht:approved ; -. + UNION + { + FILTER ($this = ex:InvalidResource) . + } + }""" ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of pre-binding in UNION" ; + 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:InvalidResource ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraint ex:TestShape-sparql ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-003.ttl b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-003.ttl index 2cc510c4..e9edc4e1 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-003.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-003.ttl @@ -1,67 +1,67 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex: - sh:declare [ - sh:prefix "ex" ; - sh:namespace "http://datashapes.org/sh/tests/sparql/pre-binding/pre-binding-003.test#"^^xsd:anyURI ; - ] . - -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:sparql ex:TestShape-sparql ; - sh:targetNode ex:InvalidResource ; -. -ex:TestShape-sparql - sh:prefixes ex: ; +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex: + sh:declare [ + sh:prefix "ex" ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + ] . + +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:sparql ex:TestShape-sparql ; + sh:targetNode ex:InvalidResource ; +. +ex:TestShape-sparql + sh:prefixes ex: ; sh:select """ SELECT $this - WHERE { - { - { - FILTER ($this = ex:InvalidResource) . - } - FILTER bound($this) . - } + WHERE { + { + { + FILTER ($this = ex:InvalidResource) . + } + FILTER bound($this) . + } FILTER (true) . - }""" ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of pre-binding in inner {...} blocks" ; - 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:InvalidResource ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint ex:TestShape-sparql ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource ; - ] ; - ] ; - mf:status sht:approved ; -. + }""" ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of pre-binding in inner {...} blocks" ; + 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:InvalidResource ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraint ex:TestShape-sparql ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-004.ttl b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-004.ttl index e19c2e0d..3fac36e3 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-004.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-004.ttl @@ -1,62 +1,62 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex: - sh:declare [ - sh:prefix "ex" ; - sh:namespace "http://datashapes.org/sh/tests/sparql/pre-binding/pre-binding-004.test#"^^xsd:anyURI ; - ] . - -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:sparql ex:TestShape-sparql ; - sh:targetNode ex:InvalidResource ; -. -ex:TestShape-sparql - sh:prefixes ex: ; +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex: + sh:declare [ + sh:prefix "ex" ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + ] . + +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:sparql ex:TestShape-sparql ; + sh:targetNode ex:InvalidResource ; +. +ex:TestShape-sparql + sh:prefixes ex: ; sh:select """ SELECT $this - WHERE { - BIND ($this AS ?that) . - FILTER (?that = ex:InvalidResource) . - }""" ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of pre-binding in BIND expressions" ; - 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:InvalidResource ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint ex:TestShape-sparql ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource ; - ] ; - ] ; - mf:status sht:approved ; -. + WHERE { + BIND ($this AS ?that) . + FILTER (?that = ex:InvalidResource) . + }""" ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of pre-binding in BIND expressions" ; + 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:InvalidResource ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraint ex:TestShape-sparql ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-005.ttl b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-005.ttl index 83790bb3..feb3b3bb 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-005.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-005.ttl @@ -1,68 +1,68 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex: - sh:declare [ - sh:prefix "ex" ; - sh:namespace "http://datashapes.org/sh/tests/sparql/pre-binding/pre-binding-005.test#"^^xsd:anyURI ; - ] . - -ex:InvalidResource - ex:property "Label" . - -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:sparql ex:TestShape-sparql ; - sh:targetNode ex:InvalidResource ; -. -ex:TestShape-sparql - sh:prefixes ex: ; +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex: + sh:declare [ + sh:prefix "ex" ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + ] . + +ex:InvalidResource + ex:property "Label" . + +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:sparql ex:TestShape-sparql ; + sh:targetNode ex:InvalidResource ; +. +ex:TestShape-sparql + sh:prefixes ex: ; sh:select """ SELECT $this - WHERE { - { - FILTER (bound($this)) - } - $this ex:property "Label" . - FILTER (bound($this)) . - }""" ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of pre-binding in BGP and FILTER" ; - 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:InvalidResource ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint ex:TestShape-sparql ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource ; - ] ; - ] ; - mf:status sht:approved ; -. + WHERE { + { + FILTER (bound($this)) + } + $this ex:property "Label" . + FILTER (bound($this)) . + }""" ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of pre-binding in BGP and FILTER" ; + 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:InvalidResource ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraint ex:TestShape-sparql ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-006.ttl b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-006.ttl index 5e8062b6..23459279 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-006.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-006.ttl @@ -1,54 +1,54 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex: - sh:declare [ - sh:prefix "ex" ; - sh:namespace "http://datashapes.org/sh/tests/sparql/pre-binding/pre-binding-006.test#"^^xsd:anyURI ; - ] . - -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:sparql ex:TestShape-sparql ; - sh:targetNode ex:InvalidResource ; -. -ex:TestShape-sparql - sh:prefixes ex: ; +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex: + sh:declare [ + sh:prefix "ex" ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + ] . + +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:sparql ex:TestShape-sparql ; + sh:targetNode ex:InvalidResource ; +. +ex:TestShape-sparql + sh:prefixes ex: ; sh:select """ SELECT $this - WHERE { - { - SELECT * - WHERE { - FILTER ($this = ex:InvalidResource) . - } - } - }""" ; -. -ex:ValidResource1 - rdf:type rdfs:Resource ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of pre-binding in nested SELECT" ; - mf:action [ - sht:dataGraph <> ; - sht:shapesGraph <> ; - ] ; - mf:result sht:Failure ; - mf:status sht:approved ; -. + WHERE { + { + SELECT * + WHERE { + FILTER ($this = ex:InvalidResource) . + } + } + }""" ; +. +ex:ValidResource1 + rdf:type rdfs:Resource ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of pre-binding in nested SELECT" ; + mf:action [ + sht:dataGraph <> ; + sht:shapesGraph <> ; + ] ; + mf:result sht:Failure ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-007.ttl b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-007.ttl index bba550e6..8e05b711 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-007.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/pre-binding-007.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . @@ -11,7 +11,7 @@ ex: sh:declare [ sh:prefix "ex" ; - sh:namespace "http://datashapes.org/sh/tests/sparql/pre-binding/pre-binding-007.test#"^^xsd:anyURI ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; ] . ex:TestShape diff --git a/shacl12-test-suite/tests/sparql/pre-binding/shapesGraph-001.ttl b/shacl12-test-suite/tests/sparql/pre-binding/shapesGraph-001.ttl index c8058512..112368ab 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/shapesGraph-001.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/shapesGraph-001.ttl @@ -1,64 +1,64 @@ -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex: - sh:declare [ - sh:prefix "ex" ; - sh:namespace "http://datashapes.org/sh/tests/sparql/pre-binding/shapesGraph-001.test#"^^xsd:anyURI ; - ] . - -ex:TestShape - rdf:type sh:NodeShape ; - rdfs:label "Test shape" ; - sh:sparql ex:TestShape-sparql ; - sh:targetNode ex:InvalidResource ; - ex:property 42 ; -. -ex:TestShape-sparql - sh:message "Test message" ; - sh:prefixes ex: ; +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex: + sh:declare [ + sh:prefix "ex" ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + ] . + +ex:TestShape + rdf:type sh:NodeShape ; + rdfs:label "Test shape" ; + sh:sparql ex:TestShape-sparql ; + sh:targetNode ex:InvalidResource ; + ex:property 42 ; +. +ex:TestShape-sparql + sh:message "Test message" ; + sh:prefixes ex: ; sh:select """ SELECT $this - WHERE { - FILTER bound($shapesGraph) . - GRAPH $shapesGraph { - FILTER bound($currentShape) . - $currentShape ex:property 42 . + WHERE { + FILTER bound($shapesGraph) . + GRAPH $shapesGraph { + FILTER bound($currentShape) . + $currentShape ex:property 42 . } - }""" ; -. -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of $shapesGraph and $currentShape" ; - 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:InvalidResource ; - sh:resultMessage "Test message" ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint ex:TestShape-sparql ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape ex:TestShape ; - sh:value ex:InvalidResource ; - ] ; - ] ; - mf:status sht:approved ; -. + }""" ; +. +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of $shapesGraph and $currentShape" ; + 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:InvalidResource ; + sh:resultMessage "Test message" ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraint ex:TestShape-sparql ; + sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; + sh:sourceShape ex:TestShape ; + sh:value ex:InvalidResource ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-001.ttl b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-001.ttl index ddc007aa..4ec83357 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-001.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-001.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-002.ttl b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-002.ttl index 529ef9a0..960e6724 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-002.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-002.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-003.ttl b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-003.ttl index 02c191ec..0fa880d4 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-003.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-003.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-004.ttl b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-004.ttl index 7ebf22fa..a4036efa 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-004.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-004.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-005.ttl b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-005.ttl index 3d47bce5..4b329021 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-005.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-005.ttl @@ -1,4 +1,4 @@ -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-006.ttl b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-006.ttl index 89f43743..30ebeeab 100644 --- a/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-006.ttl +++ b/shacl12-test-suite/tests/sparql/pre-binding/unsupported-sparql-006.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/sparql/property/property-select-001.ttl b/shacl12-test-suite/tests/sparql/property/property-select-001.ttl index 95d72cae..1530e9c8 100644 --- a/shacl12-test-suite/tests/sparql/property/property-select-001.ttl +++ b/shacl12-test-suite/tests/sparql/property/property-select-001.ttl @@ -1,73 +1,73 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Person-fullName - a sh:PropertyShape ; - sh:targetClass ex:Person ; - sh:name "full name" ; - sh:path ex:fullName ; - sh:values [ - sh:prefixes ; - sh:select """ - SELECT ?fullName - WHERE { - $this ex:firstName ?firstName . - $this ex:lastName ?lastName . - BIND (CONCAT(?firstName, " ", ?lastName) AS ?fullName) . - } - """ - ] ; - sh:datatype xsd:string ; - sh:hasValue "John Muir" . - - - a owl:Ontology ; - sh:declare [ - sh:prefix "ex" ; - sh:namespace "http://example.org/ns#"^^xsd:anyURI ; - ] . - -ex:JohnMuir - a ex:Person ; - ex:firstName "John" ; - ex:lastName "Muir" . - -ex:JohnWayne - a ex:Person ; - ex:firstName "John" ; - ex:lastName "Wayne" . - -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of a sh:property with a sh:select expression 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:JohnWayne ; - sh:resultPath ex:fullName ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:HasValueConstraintComponent ; - sh:sourceShape ex:Person-fullName ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Person-fullName + a sh:PropertyShape ; + sh:targetClass ex:Person ; + sh:name "full name" ; + sh:path ex:fullName ; + sh:values [ + sh:prefixes ; + sh:select """ + SELECT ?fullName + WHERE { + $this ex:firstName ?firstName . + $this ex:lastName ?lastName . + BIND (CONCAT(?firstName, " ", ?lastName) AS ?fullName) . + } + """ + ] ; + sh:datatype xsd:string ; + sh:hasValue "John Muir" . + + + a owl:Ontology ; + sh:declare [ + sh:prefix "ex" ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + ] . + +ex:JohnMuir + a ex:Person ; + ex:firstName "John" ; + ex:lastName "Muir" . + +ex:JohnWayne + a ex:Person ; + ex:firstName "John" ; + ex:lastName "Wayne" . + +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of a sh:property with a sh:select expression 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:JohnWayne ; + sh:resultPath ex:fullName ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:HasValueConstraintComponent ; + sh:sourceShape ex:Person-fullName ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/property/property-sparqlExpr-001.ttl b/shacl12-test-suite/tests/sparql/property/property-sparqlExpr-001.ttl index 584fdd04..df6eb505 100644 --- a/shacl12-test-suite/tests/sparql/property/property-sparqlExpr-001.ttl +++ b/shacl12-test-suite/tests/sparql/property/property-sparqlExpr-001.ttl @@ -1,58 +1,58 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:Resource-uriLength - a sh:PropertyShape ; - sh:targetNode ex:Invalid ; # The URI of this has 29 chars - sh:targetNode ex:Valid ; # The URI of this has 27 chars - sh:name "URI length" ; - - sh:path ex:uriLength ; - sh:values [ - sh:sparqlExpr "STRLEN(STR($this))" ; - sh:prefixes ; - ] ; - sh:datatype xsd:integer ; - sh:hasValue 27 . - - - a owl:Ontology ; - sh:declare [ - sh:prefix "ex" ; - sh:namespace "http://example.org/ns#"^^xsd:anyURI ; - ] . - -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of a sh:property with a sh:sparqlExpr expression 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:Invalid ; - sh:resultPath ex:uriLength ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:HasValueConstraintComponent ; - sh:sourceShape ex:Resource-uriLength ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:Resource-uriLength + a sh:PropertyShape ; + sh:targetNode ex:Invalid ; # The URI of this has 29 chars + sh:targetNode ex:Valid ; # The URI of this has 27 chars + sh:name "URI length" ; + + sh:path ex:uriLength ; + sh:values [ + sh:sparqlExpr "STRLEN(STR($this))" ; + sh:prefixes ; + ] ; + sh:datatype xsd:integer ; + sh:hasValue 27 . + + + a owl:Ontology ; + sh:declare [ + sh:prefix "ex" ; + sh:namespace "http://example.com/ns#"^^xsd:anyURI ; + ] . + +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of a sh:property with a sh:sparqlExpr expression 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:Invalid ; + sh:resultPath ex:uriLength ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:HasValueConstraintComponent ; + sh:sourceShape ex:Resource-uriLength ; + ] ; + ] ; + mf:status sht:approved ; +. diff --git a/shacl12-test-suite/tests/sparql/property/sparql-001.ttl b/shacl12-test-suite/tests/sparql/property/sparql-001.ttl index d7aae032..d7674fab 100644 --- a/shacl12-test-suite/tests/sparql/property/sparql-001.ttl +++ b/shacl12-test-suite/tests/sparql/property/sparql-001.ttl @@ -1,5 +1,5 @@ @prefix dash: . -@prefix ex: . +@prefix ex: . @prefix mf: . @prefix owl: . @prefix rdf: . diff --git a/shacl12-test-suite/tests/sparql/targets/targetNode-select-001.ttl b/shacl12-test-suite/tests/sparql/targets/targetNode-select-001.ttl index 7fedbd81..a20d1c45 100644 --- a/shacl12-test-suite/tests/sparql/targets/targetNode-select-001.ttl +++ b/shacl12-test-suite/tests/sparql/targets/targetNode-select-001.ttl @@ -1,73 +1,73 @@ -@prefix dash: . -@prefix ex: . -@prefix mf: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix sht: . -@prefix xsd: . - -ex:ChildShape - a sh:NodeShape ; - rdfs:label "Child shape" ; - rdfs:comment "This shape applies to all persons under 18 years of age." ; - sh:targetNode [ - sh:select """ - PREFIX ex: - SELECT ?person - WHERE { - ?person a/rdfs:subClassOf* ex:Person . - ?person ex:age ?age . - FILTER (?age < 18) . - } - """ - ] ; - sh:property ex:ChildShape-driversLicense . - -ex:ChildShape-driversLicense - a sh:PropertyShape ; - sh:path ex:driversLicense ; - sh:maxCount 0 . - -ex:Benjamin - a ex:Person ; - ex:driversLicense "123" ; - ex:age 17 . - -ex:Klaus - a ex:Person ; - ex:driversLicense "456" ; - ex:age 48 . - -ex:Bernd - a ex:Person ; - ex:driversLicense "789" . - -<> - rdf:type mf:Manifest ; - mf:entries ( - - ) ; -. - - rdf:type sht:Validate ; - rdfs:label "Test of sh:targetNode with a sh:select expression 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:Benjamin ; - sh:resultPath ex:driversLicense ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; - sh:sourceShape ex:ChildShape-driversLicense ; - ] ; - ] ; - mf:status sht:approved ; -. +@prefix dash: . +@prefix ex: . +@prefix mf: . +@prefix owl: . +@prefix rdf: . +@prefix rdfs: . +@prefix sh: . +@prefix sht: . +@prefix xsd: . + +ex:ChildShape + a sh:NodeShape ; + rdfs:label "Child shape" ; + rdfs:comment "This shape applies to all persons under 18 years of age." ; + sh:targetNode [ + sh:select """ + PREFIX ex: + SELECT ?person + WHERE { + ?person a/rdfs:subClassOf* ex:Person . + ?person ex:age ?age . + FILTER (?age < 18) . + } + """ + ] ; + sh:property ex:ChildShape-driversLicense . + +ex:ChildShape-driversLicense + a sh:PropertyShape ; + sh:path ex:driversLicense ; + sh:maxCount 0 . + +ex:Benjamin + a ex:Person ; + ex:driversLicense "123" ; + ex:age 17 . + +ex:Klaus + a ex:Person ; + ex:driversLicense "456" ; + ex:age 48 . + +ex:Bernd + a ex:Person ; + ex:driversLicense "789" . + +<> + rdf:type mf:Manifest ; + mf:entries ( + + ) ; +. + + rdf:type sht:Validate ; + rdfs:label "Test of sh:targetNode with a sh:select expression 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:Benjamin ; + sh:resultPath ex:driversLicense ; + sh:resultSeverity sh:Violation ; + sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; + sh:sourceShape ex:ChildShape-driversLicense ; + ] ; + ] ; + mf:status sht:approved ; +.