Skip to content

Commit 00106de

Browse files
committed
Remove lightly used variables
An RDFLib namespace dictionary can take a `Namespace` object as its value. So, this patch aligns variable definition practice with elsewhere in this code base, not separating out an `IRI_` variable for each namesapce. Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
1 parent 94130d4 commit 00106de

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

tests/case_utils/case_file/test_case_file.py

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,19 +22,15 @@
2222

2323
_logger = logging.getLogger(os.path.basename(__file__))
2424

25-
IRI_UCO_CORE = "https://unifiedcyberontology.org/ontology/uco/core#"
26-
IRI_UCO_OBSERVABLE = "https://unifiedcyberontology.org/ontology/uco/observable#"
27-
IRI_UCO_TYPES = "https://unifiedcyberontology.org/ontology/uco/types#"
28-
2925
NS_RDF = rdflib.RDF
30-
NS_UCO_CORE = rdflib.Namespace(IRI_UCO_CORE)
31-
NS_UCO_OBSERVABLE = rdflib.Namespace(IRI_UCO_OBSERVABLE)
32-
NS_UCO_TYPES = rdflib.Namespace(IRI_UCO_TYPES)
26+
NS_UCO_CORE = rdflib.Namespace("https://unifiedcyberontology.org/ontology/uco/core#")
27+
NS_UCO_OBSERVABLE = rdflib.Namespace("https://unifiedcyberontology.org/ontology/uco/observable#")
28+
NS_UCO_TYPES = rdflib.Namespace("https://unifiedcyberontology.org/ontology/uco/types#")
3329

3430
NSDICT = {
35-
"uco-core": IRI_UCO_CORE,
36-
"uco-observable": IRI_UCO_OBSERVABLE,
37-
"uco-types": IRI_UCO_TYPES,
31+
"uco-core": NS_UCO_CORE,
32+
"uco-observable": NS_UCO_OBSERVABLE,
33+
"uco-types": NS_UCO_TYPES,
3834
}
3935

4036
SRCDIR = os.path.dirname(__file__)

0 commit comments

Comments
 (0)