Skip to content

Commit 63afdfc

Browse files
committed
Backport rdf-toolkit version as test library
This patch isolates a change needed to get patch-releases atop 0.5.0 to pass `make check`. This patch alone will not pass `make check`; see the following octopus merge for a commit that passes `make check`. No effects were observed on Make-managed files. References: * ucoProject/UCO#373 Signed-off-by: Alex Nelson <[email protected]>
1 parent 33d9565 commit 63afdfc

File tree

9 files changed

+58
-19
lines changed

9 files changed

+58
-19
lines changed

.github/workflows/cicd.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ jobs:
2727

2828
steps:
2929
- uses: actions/checkout@v2
30-
- uses: actions/setup-java@v2
30+
- uses: actions/setup-java@v3
3131
with:
32-
distribution: 'adopt'
33-
java-version: '8'
32+
distribution: 'temurin'
33+
java-version: '11'
3434
- name: Set up Python ${{ matrix.python-version }}
3535
uses: actions/setup-python@v2
3636
with:

tests/Makefile

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ all: \
2222

2323
.PHONY: \
2424
all-case_utils \
25+
all-lib \
2526
check-case_utils \
2627
check-isomorphic_diff \
2728
check-mypy \
@@ -53,10 +54,15 @@ all: \
5354
touch $@
5455

5556
all-case_utils: \
56-
.venv.done.log
57+
.venv.done.log \
58+
all-lib
5759
$(MAKE) \
5860
--directory case_utils
5961

62+
all-lib:
63+
$(MAKE) \
64+
--directory lib
65+
6066
# These check calls are provided in preferred run-order.
6167
check: \
6268
check-mypy \
@@ -68,7 +74,8 @@ check: \
6874
--log-level=DEBUG
6975

7076
check-case_utils: \
71-
.venv.done.log
77+
.venv.done.log \
78+
all-lib
7279
$(MAKE) \
7380
--directory case_utils \
7481
check

tests/case_utils/case_file/Makefile

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,7 @@ top_srcdir := $(shell cd ../../.. ; pwd)
1717

1818
tests_srcdir := $(top_srcdir)/tests
1919

20-
case_srcdir := $(top_srcdir)/dependencies/CASE
21-
22-
RDF_TOOLKIT_JAR := $(case_srcdir)/lib/rdf-toolkit.jar
20+
RDF_TOOLKIT_JAR := $(tests_srcdir)/lib/rdf-toolkit.jar
2321

2422
all: \
2523
kb.json \

tests/case_utils/case_validate/case_test_examples/Makefile

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,11 @@ SHELL := /bin/bash
1515

1616
top_srcdir := $(shell cd ../../../.. ; pwd)
1717

18-
case_srcdir := $(top_srcdir)/dependencies/CASE
19-
20-
examples_srcdir := $(case_srcdir)/tests/examples
18+
examples_srcdir := $(top_srcdir)/dependencies/CASE/tests/examples
2119

2220
tests_srcdir := $(top_srcdir)/tests
2321

24-
RDF_TOOLKIT_JAR := $(case_srcdir)/lib/rdf-toolkit.jar
22+
RDF_TOOLKIT_JAR := $(tests_srcdir)/lib/rdf-toolkit.jar
2523

2624
all: \
2725
investigative_action_PASS_validation.ttl \

tests/case_utils/case_validate/cli/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ examples_srcdir := $(case_srcdir)/tests/examples
2121

2222
tests_srcdir := $(top_srcdir)/tests
2323

24-
RDF_TOOLKIT_JAR := $(case_srcdir)/lib/rdf-toolkit.jar
24+
RDF_TOOLKIT_JAR := $(tests_srcdir)/lib/rdf-toolkit.jar
2525

2626
files_to_generate := \
2727
format_human_output_jsonld.jsonld \

tests/case_utils/case_validate/uco_test_examples/Makefile

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,11 @@ SHELL := /bin/bash
1515

1616
top_srcdir := $(shell cd ../../../.. ; pwd)
1717

18-
case_srcdir := $(top_srcdir)/dependencies/CASE
19-
20-
uco_srcdir := $(case_srcdir)/dependencies/UCO
21-
22-
examples_srcdir := $(uco_srcdir)/tests/examples
18+
examples_srcdir := $(top_srcdir)/dependencies/CASE/dependencies/UCO/tests/examples
2319

2420
tests_srcdir := $(top_srcdir)/tests
2521

26-
RDF_TOOLKIT_JAR := $(case_srcdir)/lib/rdf-toolkit.jar
22+
RDF_TOOLKIT_JAR := $(tests_srcdir)/lib/rdf-toolkit.jar
2723

2824
all: \
2925
action_inheritance_PASS_validation.ttl \

tests/lib/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.jar

tests/lib/Makefile

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
#!/usr/bin/make -f
2+
3+
# Portions of this file contributed by NIST are governed by the
4+
# following statement:
5+
#
6+
# This software was developed at the National Institute of Standards
7+
# and Technology by employees of the Federal Government in the course
8+
# of their official duties. Pursuant to Title 17 Section 105 of the
9+
# United States Code, this software is not subject to copyright
10+
# protection within the United States. NIST assumes no responsibility
11+
# whatsoever for its use by other parties, and makes no guarantees,
12+
# expressed or implied, about its quality, reliability, or any other
13+
# characteristic.
14+
#
15+
# We would appreciate acknowledgement if the software is used.
16+
17+
# This Makefile is incorporated to support versions of case-utils since
18+
# 0.5.0 that had not yet incorporated rdf-toolkit-1.11.0.jar into their
19+
# testing process. The Makefile is adapted from the `/lib` directory of
20+
# UCO at version 1.2.0.
21+
22+
SHELL := /bin/bash
23+
24+
all: \
25+
rdf-toolkit.jar
26+
27+
rdf-toolkit.jar:
28+
test -r rdf-toolkit.jar.sha512
29+
rm -f $@_
30+
# Try retrieval from files.caseontology.org.
31+
wget \
32+
--output-document $@_ \
33+
https://files.caseontology.org/rdf-toolkit-1.11.0.jar
34+
test \
35+
"x$$(openssl dgst -sha512 $@_ | awk '{print($$NF)}')" \
36+
== \
37+
"x$$(head -n1 rdf-toolkit.jar.sha512)"
38+
mv $@_ $@

tests/lib/rdf-toolkit.jar.sha512

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
8131e5515da63f099a89a3ce2c7587fb6b228f1ec7c5eb49ff35710509e8511921bfc847e182ee994e575b1f7895c04ae5bed7e1b7826bb32c9475b43b74dc17

0 commit comments

Comments
 (0)