Class SPARQLComplianceTest

java.lang.Object
org.eclipse.rdf4j.testsuite.query.parser.sparql.manifest.SPARQLComplianceTest
Direct Known Subclasses:
SPARQL11UpdateComplianceTest, SPARQLQueryComplianceTest, SPARQLSyntaxComplianceTest

public abstract class SPARQLComplianceTest extends Object
Base functionality for SPARQL compliance test suites using a W3C-style Manifest.
Author:
Jeen Broekstra
  • Constructor Details

    • SPARQLComplianceTest

      public SPARQLComplianceTest(String displayName, String testURI, String name)
      Parameters:
      displayName -
      testURI -
      name -
  • Method Details

    • test

      public void test() throws Exception
      Throws:
      Exception
    • getDisplayName

      public String getDisplayName()
      Returns:
      the displayName
    • getTestURI

      public String getTestURI()
      Returns:
      the testURI
    • getName

      public String getName()
      Returns:
      the name
    • runTest

      protected abstract void runTest() throws Exception
      Throws:
      Exception
    • getDataRepository

      protected abstract Repository getDataRepository()
    • includeSubManifest

      protected static boolean includeSubManifest(String subManifestFile, List<String> excludedSubdirs)
      Verifies if the selected subManifest occurs in the supplied list of excluded subdirs.
      Parameters:
      subManifestFile - the url of a sub-manifest
      excludedSubdirs - an array of directory names. May be null.
      Returns:
      false if the supplied list of excluded subdirs is not empty and contains a match for the supplied sub-manifest, true otherwise.
    • uploadDataset

      protected void uploadDataset(Dataset dataset) throws Exception
      Throws:
      Exception
    • upload

      protected void upload(IRI graphURI, Resource context) throws Exception
      Throws:
      Exception
    • printBindingSet

      protected static final void printBindingSet(BindingSet bs, StringBuilder appendable)
    • getIgnoredTests

      protected List<String> getIgnoredTests()
      Returns:
      the ignoredTests
    • addIgnoredTest

      protected void addIgnoredTest(String ignoredTest)
    • setIgnoredTests

      protected void setIgnoredTests(List<String> ignoredTests)
      Parameters:
      ignoredTests - the ignoredTests to set
    • compareGraphs

      protected void compareGraphs(Iterable<Statement> queryResult, Iterable<Statement> expectedResult) throws Exception
      Throws:
      Exception