Skip to content

Commit cd178f3

Browse files
authored
Merge pull request #143 from casework/deactivate_errant_rdf_list_shape
Deactivate List shape when TBox review is not requested
2 parents 26122e7 + ead3b17 commit cd178f3

File tree

2 files changed

+32
-0
lines changed

2 files changed

+32
-0
lines changed

case_utils/case_validate/validate_utils.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,7 @@ def disable_tbox_review(graph: rdflib.Graph) -> None:
197197
"Disjointedness-AP-OP-shape",
198198
"Disjointedness-C-DT-shape",
199199
"Disjointedness-DP-OP-shape",
200+
"List-shape",
200201
"ObjectProperty-shacl-constraints-shape",
201202
"ontologyIRI-versionIRI-prerequisite-shape",
202203
"versionIRI-nodeKind-shape",

tests/case_utils/case_validate/uco_test_examples/Makefile

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,37 @@ all: \
102102
rm __$@
103103
mv _$@ $@
104104

105+
# NOTE - this more-specific recipe enables "tbox" review, but otherwise
106+
# matches the wildcarded recipe.
107+
rdf_list_XFAIL_validation.ttl: \
108+
$(examples_srcdir)/rdf_list_XFAIL.json \
109+
$(tests_srcdir)/.venv.done.log \
110+
$(top_srcdir)/.ontology.done.log \
111+
$(top_srcdir)/case_utils/case_validate/__init__.py \
112+
$(top_srcdir)/case_utils/case_validate/validate_types.py \
113+
$(top_srcdir)/case_utils/case_validate/validate_utils.py \
114+
$(top_srcdir)/case_utils/ontology/__init__.py
115+
source $(tests_srcdir)/venv/bin/activate \
116+
&& case_validate \
117+
--allow-warnings \
118+
--debug \
119+
--format turtle \
120+
--review-tbox \
121+
$< \
122+
> __$@ \
123+
; rc=$$? ; test 0 -eq $$rc -o 1 -eq $$rc
124+
@#Fail if output is empty.
125+
@test -s __$@ \
126+
|| exit 1
127+
java -jar $(RDF_TOOLKIT_JAR) \
128+
--inline-blank-nodes \
129+
--source __$@ \
130+
--source-format turtle \
131+
--target _$@ \
132+
--target-format turtle
133+
rm __$@
134+
mv _$@ $@
135+
105136
# NOTE - this more-specific recipe enables "tbox" review, but otherwise
106137
# matches the wildcarded recipe.
107138
owl_properties_XFAIL_validation.ttl: \

0 commit comments

Comments
 (0)