-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
74f46d4
commit 8ed6954
Showing
3 changed files
with
113 additions
and
94 deletions.
There are no files selected for viewing
57 changes: 57 additions & 0 deletions
57
...ompany/qendpoint/store/experimental/ExperimentalQEndpointSPARQL11ComplianceQueryTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
package com.the_qa_company.qendpoint.store.experimental; | ||
|
||
import com.the_qa_company.qendpoint.core.options.HDTOptions; | ||
import com.the_qa_company.qendpoint.core.options.HDTOptionsKeys; | ||
import com.the_qa_company.qendpoint.store.Utility; | ||
import org.eclipse.rdf4j.repository.Repository; | ||
import org.eclipse.rdf4j.repository.sail.SailRepository; | ||
import org.eclipse.rdf4j.sail.NotifyingSailConnection; | ||
import org.eclipse.rdf4j.testsuite.query.parser.sparql.manifest.SPARQL11QueryComplianceTest; | ||
import org.junit.jupiter.api.io.TempDir; | ||
|
||
import java.nio.file.Path; | ||
import java.util.ArrayList; | ||
import java.util.List; | ||
|
||
public class ExperimentalQEndpointSPARQL11ComplianceQueryTest extends SPARQL11QueryComplianceTest { | ||
/* | ||
* Set this to true to print the call to the store when doing the compliance | ||
* tests | ||
*/ | ||
private static final boolean PRINT_CALLS = false; | ||
|
||
/* | ||
* Set this to false to enable the graph tests | ||
*/ | ||
private static final boolean DISABLE_GRAPH_TESTS = true; | ||
|
||
@TempDir | ||
public Path tempDir; | ||
|
||
public ExperimentalQEndpointSPARQL11ComplianceQueryTest() { | ||
|
||
if (DISABLE_GRAPH_TESTS) { | ||
this.setIgnoredTests(new ArrayList<>(List.of("constructwhere04 - CONSTRUCT WHERE", | ||
"Exists within graph pattern", "(pp07) Path with one graph", "(pp34) Named Graph 1", | ||
"(pp35) Named Graph 2", "sq01 - Subquery within graph pattern", | ||
"sq02 - Subquery within graph pattern, graph variable is bound", | ||
"sq03 - Subquery within graph pattern, graph variable is not bound", | ||
"sq04 - Subquery within graph pattern, default graph does not apply", | ||
"sq05 - Subquery within graph pattern, from named applies", | ||
"sq06 - Subquery with graph pattern, from named applies", "sq07 - Subquery with from", | ||
"sq11 - Subquery limit per resource", "sq13 - Subqueries don't inject bindings"))); | ||
} | ||
} | ||
|
||
@Override | ||
protected Repository newRepository() throws Exception { | ||
HDTOptions spec = HDTOptions.of(HDTOptionsKeys.DICTIONARY_TYPE_KEY, | ||
HDTOptionsKeys.DICTIONARY_TYPE_VALUE_MULTI_OBJECTS_LANG); | ||
ExperimentalQEndpointSail sail = new ExperimentalQEndpointSail(tempDir, spec); | ||
|
||
if (PRINT_CALLS) { | ||
return Utility.convertToDumpRepository(new SailRepository(Utility.convertToDumpSail(sail))); | ||
} | ||
return new SailRepository(sail); | ||
} | ||
} |
94 changes: 0 additions & 94 deletions
94
..._qa_company/qendpoint/store/experimental/ExperimentalQEndpointSPARQL11ComplianceTest.java
This file was deleted.
Oops, something went wrong.
56 changes: 56 additions & 0 deletions
56
...mpany/qendpoint/store/experimental/ExperimentalQEndpointSPARQL11ComplianceUpdateTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
package com.the_qa_company.qendpoint.store.experimental; | ||
|
||
import com.the_qa_company.qendpoint.core.options.HDTOptions; | ||
import com.the_qa_company.qendpoint.core.options.HDTOptionsKeys; | ||
import com.the_qa_company.qendpoint.store.Utility; | ||
import org.eclipse.rdf4j.repository.Repository; | ||
import org.eclipse.rdf4j.repository.sail.SailRepository; | ||
import org.eclipse.rdf4j.sail.NotifyingSailConnection; | ||
import org.eclipse.rdf4j.testsuite.query.parser.sparql.manifest.SPARQL11UpdateComplianceTest; | ||
import org.junit.jupiter.api.io.TempDir; | ||
|
||
import java.nio.file.Files; | ||
import java.nio.file.Path; | ||
import java.util.ArrayList; | ||
import java.util.List; | ||
|
||
public class ExperimentalQEndpointSPARQL11ComplianceUpdateTest extends SPARQL11UpdateComplianceTest { | ||
/* | ||
* Set this to true to print the call to the store when doing the compliance | ||
* tests | ||
*/ | ||
private static final boolean PRINT_CALLS = false; | ||
|
||
/* | ||
* Set this to false to enable the graph tests | ||
*/ | ||
private static final boolean DISABLE_GRAPH_TESTS = true; | ||
|
||
@TempDir | ||
public Path tempDir; | ||
|
||
public ExperimentalQEndpointSPARQL11ComplianceUpdateTest() { | ||
|
||
if (DISABLE_GRAPH_TESTS) { | ||
this.setIgnoredTests(new ArrayList<>(List.of("INSERT 03", "INSERT 04", "INSERT USING 01", | ||
"DELETE INSERT 1b", "DELETE INSERT 1c", "INSERT same bnode twice", "CLEAR NAMED", "DROP NAMED", | ||
"DROP GRAPH", "DROP DEFAULT", "CLEAR GRAPH", "CLEAR DEFAULT", "COPY 1", "COPY 3", "COPY 6", | ||
"MOVE 1", "MOVE 3", "MOVE 6", "Graph-specific DELETE DATA 1", "Graph-specific DELETE DATA 2", | ||
"Graph-specific DELETE 1", "Graph-specific DELETE 1 (WITH)", "Graph-specific DELETE 1 (USING)", | ||
"Simple DELETE 1 (USING)", "Simple DELETE 2 (WITH)", "Simple DELETE 4 (WITH)"))); | ||
} | ||
} | ||
|
||
@Override | ||
protected Repository newRepository() throws Exception { | ||
HDTOptions spec = HDTOptions.of(HDTOptionsKeys.DICTIONARY_TYPE_KEY, | ||
HDTOptionsKeys.DICTIONARY_TYPE_VALUE_MULTI_OBJECTS_LANG); | ||
ExperimentalQEndpointSail sail = new ExperimentalQEndpointSail(tempDir, spec); | ||
|
||
if (PRINT_CALLS) { | ||
return Utility.convertToDumpRepository(new SailRepository(Utility.convertToDumpSail(sail))); | ||
} | ||
return new SailRepository(sail); | ||
} | ||
|
||
} |