aboutsummaryrefslogtreecommitdiffstats
path: root/test/lib/test_pipeline.py
diff options
context:
space:
mode:
authorMatthias Baumgartner <dev@igsor.net>2023-03-05 19:22:46 +0100
committerMatthias Baumgartner <dev@igsor.net>2023-03-05 19:22:46 +0100
commitaf81318ae9311fd0b0e16949cef3cfaf7996970b (patch)
treefb220da28bb7248ebf37ce09af5de88f2c1aaad4 /test/lib/test_pipeline.py
parent7bf6b33fa6d6b901e4933bfe0b2a9939d7b3f3f3 (diff)
parent8b460aa0232cd841af7b7734c91982bc83486e03 (diff)
downloadbsie-af81318ae9311fd0b0e16949cef3cfaf7996970b.tar.gz
bsie-af81318ae9311fd0b0e16949cef3cfaf7996970b.tar.bz2
bsie-af81318ae9311fd0b0e16949cef3cfaf7996970b.zip
Merge branch 'mb/diogenes' into develop
Diffstat (limited to 'test/lib/test_pipeline.py')
-rw-r--r--test/lib/test_pipeline.py17
1 files changed, 6 insertions, 11 deletions
diff --git a/test/lib/test_pipeline.py b/test/lib/test_pipeline.py
index 61fddd7..eb088a9 100644
--- a/test/lib/test_pipeline.py
+++ b/test/lib/test_pipeline.py
@@ -1,9 +1,4 @@
-"""
-Part of the bsie test suite.
-A copy of the license is provided with the project.
-Author: Matthias Baumgartner, 2022
-"""
# standard imports
import logging
import os
@@ -28,19 +23,19 @@ class TestPipeline(unittest.TestCase):
# constant A
csA = '''
bse:author rdfs:subClassOf bsfs:Predicate ;
- rdfs:domain bsfs:File ;
+ rdfs:domain bsn:Entity ;
rdfs:range xsd:string ;
bsfs:unique "true"^^xsd:boolean .
'''
- tupA = [('http://bsfs.ai/schema/Entity#author', 'Me, myself, and I')]
+ tupA = [('https://schema.bsfs.io/ie/Node/Entity#author', 'Me, myself, and I')]
# constant B
csB = '''
bse:rating rdfs:subClassOf bsfs:Predicate ;
- rdfs:domain bsfs:File ;
+ rdfs:domain bsn:Entity ;
rdfs:range xsd:integer ;
bsfs:unique "true"^^xsd:boolean .
'''
- tupB = [('http://bsfs.ai/schema/Entity#rating', 123)]
+ tupB = [('https://schema.bsfs.io/ie/Node/Entity#rating', 123)]
# extractors/readers
self.ext2rdr = {
bsie.extractor.generic.path.Path(): bsie.reader.path.Path(),
@@ -89,13 +84,13 @@ class TestPipeline(unittest.TestCase):
pipeline = Pipeline(self.ext2rdr)
# build objects for tests
content_hash = 'a948904f2f0f479b8f8197694b30184b0d2ed1c1cd2a1ec0fb85d299a192a447'
- subject = node.Node(ns.bsfs.File, ucid=content_hash)
+ subject = node.Node(ns.bsn.Entity, ucid=content_hash)
testfile = os.path.join(os.path.dirname(__file__), 'testfile.t')
p_filename = pipeline.schema.predicate(ns.bse.filename)
p_filesize = pipeline.schema.predicate(ns.bse.filesize)
p_author = pipeline.schema.predicate(ns.bse.author)
p_rating = pipeline.schema.predicate(ns.bse.rating)
- entity = pipeline.schema.node(ns.bsfs.File)
+ entity = pipeline.schema.node(ns.bsn.Entity)
p_invalid = pipeline.schema.predicate(ns.bsfs.Predicate).child(ns.bse.foo, range=entity)
# extract given predicates