diff --git a/ontology/uco/observable/observable.ttl b/ontology/uco/observable/observable.ttl index 293cb35c..050119f7 100644 --- a/ontology/uco/observable/observable.ttl +++ b/ontology/uco/observable/observable.ttl @@ -8886,12 +8886,6 @@ observable:WindowsThreadFacet rdfs:label "WindowsThreadFacet"@en ; rdfs:comment "A Windows thread facet is a grouping os characteristics unique to a single thread of execution within a Windows process."@en ; sh:property - [ - sh:datatype xsd:dateTime ; - sh:maxCount "1"^^xsd:integer ; - sh:nodeKind sh:Literal ; - sh:path observable:creationTime ; - ] , [ sh:datatype xsd:dateTime ; sh:maxCount "1"^^xsd:integer ; @@ -10237,9 +10231,8 @@ observable:creationTime-deprecation-shape sh:property [ a sh:PropertyShape ; sh:maxCount "0"^^xsd:integer ; - sh:message "observable:creationTime is deprecated, and will be an error to use in UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; + sh:message "observable:creationTime is deprecated, and an error to use as of UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; sh:path observable:creationTime ; - sh:severity sh:Warning ; ] ; sh:targetSubjectsOf observable:creationTime ; . diff --git a/ontology/uco/types/types.ttl b/ontology/uco/types/types.ttl index 8dc0e9a1..10226c76 100644 --- a/ontology/uco/types/types.ttl +++ b/ontology/uco/types/types.ttl @@ -184,7 +184,7 @@ types:Thread ; rdfs:subClassOf co:Bag , - core:UcoThing + core:UcoInherentCharacterizationThing ; rdfs:label "Thread"@en ; rdfs:comment "A semi-ordered array of items, that can be present in multiple copies. Implemetation of a UCO Thread is similar to a Collections Ontology List, except a Thread may fork and merge - that is, one of its members may have two or more direct successors, and two or more direct predecessors."@en ; @@ -202,7 +202,7 @@ types:ThreadItem ; rdfs:subClassOf co:Item , - core:UcoThing + core:UcoInherentCharacterizationThing ; rdfs:label "ThreadItem"@en ; rdfs:comment "A ThreadItem is a member of a thread."@en ; diff --git a/tests/examples/Makefile b/tests/examples/Makefile index 9bde9ee1..0bca4ba6 100644 --- a/tests/examples/Makefile +++ b/tests/examples/Makefile @@ -36,7 +36,7 @@ all: \ location_XFAIL_validation.ttl \ message_thread_PASS_validation.ttl \ message_thread_XFAIL_validation.ttl \ - observable_creation_time_PASS_validation.ttl \ + observable_creation_time_XFAIL_validation.ttl \ owl_axiom_PASS_validation.ttl \ owl_axiom_XFAIL_validation.ttl \ owl_properties_PASS_validation.ttl \ @@ -106,7 +106,7 @@ check: \ location_XFAIL_validation.ttl \ message_thread_PASS_validation.ttl \ message_thread_XFAIL_validation.ttl \ - observable_creation_time_PASS_validation.ttl \ + observable_creation_time_XFAIL_validation.ttl \ owl_axiom_PASS_validation.ttl \ owl_axiom_XFAIL_validation.ttl \ owl_properties_PASS_validation.ttl \ diff --git a/tests/examples/observable_creation_time_PASS.json b/tests/examples/observable_creation_time_XFAIL.json similarity index 100% rename from tests/examples/observable_creation_time_PASS.json rename to tests/examples/observable_creation_time_XFAIL.json diff --git a/tests/examples/observable_creation_time_PASS_validation.ttl b/tests/examples/observable_creation_time_XFAIL_validation.ttl similarity index 66% rename from tests/examples/observable_creation_time_PASS_validation.ttl rename to tests/examples/observable_creation_time_XFAIL_validation.ttl index 60605c2c..bae4a3ea 100644 --- a/tests/examples/observable_creation_time_PASS_validation.ttl +++ b/tests/examples/observable_creation_time_XFAIL_validation.ttl @@ -7,20 +7,19 @@ [] a sh:ValidationReport ; - sh:conforms "true"^^xsd:boolean ; + sh:conforms "false"^^xsd:boolean ; sh:result [ a sh:ValidationResult ; sh:focusNode ; - sh:resultMessage "observable:creationTime is deprecated, and will be an error to use in UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; + sh:resultMessage "observable:creationTime is deprecated, and an error to use as of UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; sh:resultPath observable:creationTime ; - sh:resultSeverity sh:Warning ; + sh:resultSeverity sh:Violation ; sh:sourceConstraintComponent sh:MaxCountConstraintComponent ; sh:sourceShape [ a sh:PropertyShape ; sh:maxCount "0"^^xsd:integer ; - sh:message "observable:creationTime is deprecated, and will be an error to use in UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; + sh:message "observable:creationTime is deprecated, and an error to use as of UCO 2.0.0. observable:observableCreatedTime should be used instead."@en ; sh:path observable:creationTime ; - sh:severity sh:Warning ; ] ; ] ; . diff --git a/tests/examples/test_validation.py b/tests/examples/test_validation.py index bd079c3e..aa050259 100644 --- a/tests/examples/test_validation.py +++ b/tests/examples/test_validation.py @@ -371,16 +371,10 @@ def test_message_thread_PASS_validation() -> None: def test_message_thread_XFAIL_validation() -> None: confirm_validation_results("message_thread_XFAIL_validation.ttl", False) -def test_observable_creation_time_PASS() -> None: +def test_observable_creation_time_XFAIL() -> None: confirm_validation_results( - "observable_creation_time_PASS_validation.ttl", - True, - expected_focus_node_severities={ - ( - "http://example.org/kb/windows-thread-facet-4967ae35-f00b-49c8-9dd2-38e3bdf851e1", - str(NS_SH.Warning) - ) - } + "observable_creation_time_XFAIL_validation.ttl", + False, ) def test_owl_axiom_PASS() -> None: diff --git a/tests/shapes/examples_uco_qc/co_Collection_core_UcoObject_XFAIL.ttl b/tests/shapes/examples_uco_qc/co_Collection_core_UcoObject_XFAIL.ttl deleted file mode 100644 index 619d3675..00000000 --- a/tests/shapes/examples_uco_qc/co_Collection_core_UcoObject_XFAIL.ttl +++ /dev/null @@ -1,57 +0,0 @@ -@prefix co: . -@prefix core: . -@prefix ex: . -@prefix observable: . -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix xsd: . - -ex:IPAddressRoute - a owl:Class ; - rdfs:comment "This is expected to trigger a disjointed-classes violation, once subclass expansion occurs. This example copies subclass axioms from co:, core:, and observable:."@en ; - rdfs:subClassOf - co:List , - observable:ObservableObject - ; - . - -co:Bag - a owl:Class ; - rdfs:subClassOf co:Collection ; - . - -co:List - a owl:Class ; - rdfs:comment "This definition is excerpted from co:."@en ; - rdfs:subClassOf [ - a owl:Class ; - owl:intersectionOf ( - co:Bag - [ - a owl:Restriction ; - owl:onProperty co:item ; - owl:allValuesFrom co:ListItem ; - ] - ) ; - ] ; - . - -core:Item - a owl:Class ; - rdfs:subClassOf core:UcoObject ; - . - -observable:ObservableObject - a owl:Class ; - rdfs:subClassOf - core:Item , - observable:Observable - ; - . - -observable:Observable - a owl:Class ; - rdfs:subClassOf core:UcoObject ; - . - diff --git a/tests/shapes/examples_uco_qc/co_Collection_core_UcoObject_XFAIL_validation.ttl b/tests/shapes/examples_uco_qc/co_Collection_core_UcoObject_XFAIL_validation.ttl deleted file mode 100644 index f8a4c0e8..00000000 --- a/tests/shapes/examples_uco_qc/co_Collection_core_UcoObject_XFAIL_validation.ttl +++ /dev/null @@ -1,38 +0,0 @@ -@prefix owl: . -@prefix rdf: . -@prefix rdfs: . -@prefix sh: . -@prefix uco-qc: . -@prefix xsd: . - -[] - a sh:ValidationReport ; - sh:conforms "false"^^xsd:boolean ; - sh:result [ - a sh:ValidationResult ; - sh:focusNode ; - sh:resultMessage "The focus node is defined as a subclass of two classes intended to be disjoint, co:Collection and core:UcoObject. See Issue 509 for suggested implementation alterations." ; - sh:resultSeverity sh:Violation ; - sh:sourceConstraint [ - a sh:SPARQLConstraint ; - rdfs:seeAlso ; - sh:message "The focus node is defined as a subclass of two classes intended to be disjoint, co:Collection and core:UcoObject. See Issue 509 for suggested implementation alterations."@en ; - sh:select """ - PREFIX co: - PREFIX core: - PREFIX rdfs: - SELECT $this - WHERE { - $this - rdfs:subClassOf*/(owl:intersectionOf/rdf:rest*/rdf:first)?/rdfs:subClassOf* co:Collection ; - rdfs:subClassOf* core:UcoObject ; - . - } - """ ; - ] ; - sh:sourceConstraintComponent sh:SPARQLConstraintComponent ; - sh:sourceShape uco-qc:disjointedness-co-collection-core-uco-object ; - sh:value ; - ] ; - . - diff --git a/tests/shapes/test_qc_shapes.py b/tests/shapes/test_qc_shapes.py index 1d795e16..0a59e6da 100644 --- a/tests/shapes/test_qc_shapes.py +++ b/tests/shapes/test_qc_shapes.py @@ -24,16 +24,6 @@ @pytest.mark.parametrize( ["filename", "expected_validation_result", "expected_focus_values"], [ - ( - "examples_uco_qc/co_Collection_core_UcoObject_XFAIL_validation.ttl", - False, - { - ( - URIRef("http://example.org/ontology/IPAddressRoute"), - URIRef("http://example.org/ontology/IPAddressRoute"), - ) - } - ), ( "examples_uco_owl/owl_incompatibleWith_shape_PASS_validation.ttl", True,