A repository containing test-manifests that can be used to do integration testing. Based on the ontology-query-testing and used in the rdf-test-suite-ldf.js.
This repository consists of 4 test manifests that can be used to test the 4 query-engines of comunica.
manifest name | manifest URI | tested sources |
---|---|---|
SPARQL | sparql-manifest.ttl | TPF , FILE , SPARQL |
SPARQL-FILE | file-manifest.ttl | FILE |
SPARQL-HDT | hdt-manifest.ttl | HDT |
SPARQL-RDFJS | rdfjs-manifest.ttl | RDFJS |
In most cases, you'll want to add queries to the sparql/sparql-manifest.ttl
.
To do this, you'll have to do the following:
- Globally install
ldf-recorder
. If you made changes to Comunica that were not released yet, you may have to clone https://github.com/comunica/ldf-recorder, link your local@comunica/query-sparql
, and use that instance ofldf-recorder
for recording. - Add your new query entry to
sparql/manifest-raw.txt
. The expected format is test label and sources. If you want to record over plain files, then you may have to temporarily host the file on localhost (e.g. usinghttp-server
), and define it as such insparql/manifest-raw.txt
. After generating, make sure to add both the original file and the recorded file to git, and updatesparql/manifest-raw.txt
to refer to the original file via the URL as it will exist on GitHub (see how this is done in the other tests). - Run
./generate.sh
to generate the expected outputs of all tests insparql/manifest-raw.txt
. You could temporarily omit elements fromsparql/manifest-raw.txt
to only generate those test outputs that have changed. - Add your new query entry to
sparql/sparql-manifest.ttl
. - After testing and pushing, this can be tested in Comunica by running
yarn run integration
insideengines/query-sparql
.
A lot of the queries are inspired by the pre-built queries on query.linkeddatafragments.org.
The ontology which is used by the above named test manifests. More information can be found here ontology.
The test-suite that is able to execute the above test manifests. More information can be found here test-suite.
The tool that we used to create the mockingfiles used for TPF
- and SPARQL
- endpoint mocking while testing in the test-suite. More information can be found here recorder.