From: <tho...@us...> - 2014-11-18 12:03:34
|
Revision: 8716 http://sourceforge.net/p/bigdata/code/8716 Author: thompsonbry Date: 2014-11-18 12:03:24 +0000 (Tue, 18 Nov 2014) Log Message: ----------- Bug fixes for test suites (mainly RDR related) in preparation for 1.4.0 release. Modified Paths: -------------- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/TestReificationDoneRightEval.java branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02.ttl branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/TestProvenanceQuery.java branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/TestSids.java branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/tck/BigdataConnectionTest.java branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/org/openrdf/repository/RepositoryConnectionTest.java Added Paths: ----------- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-01.ttlx branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02.ttlx branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02a.ttlx branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-04.ttlx branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/provenance01.ttlx Removed Paths: ------------- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-04.ttl branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/provenance01.ttl Modified: branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/TestReificationDoneRightEval.java =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/TestReificationDoneRightEval.java 2014-11-17 22:11:08 UTC (rev 8715) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/TestReificationDoneRightEval.java 2014-11-18 12:03:24 UTC (rev 8716) @@ -82,7 +82,6 @@ * Reification Done Right</a> * * @author <a href="mailto:tho...@us...">Bryan Thompson</a> - * @version $Id: TestTCK.java 6261 2012-04-09 10:28:48Z thompsonbry $ */ public class TestReificationDoneRightEval extends AbstractDataDrivenSPARQLTestCase { @@ -165,6 +164,20 @@ h.runTest(); } + + /** + * Version of the above where the data are read from a file rather than being + * built up by hand. + */ + public void test_reificationDoneRight_00_loadDataFromFile() throws Exception { + + new TestHelper("reif/rdr-00-loadFromFile", // testURI, + "reif/rdr-02.rq",// queryFileURL + "reif/rdr-02.ttlx",// dataFileURL + "reif/rdr-02.srx"// resultFileURL + ).runTest(); + + } /** * Bootstrap test. The data are explicitly entered into the KB by hand. This @@ -221,18 +234,32 @@ * matching lexical items.) */ - final TestHelper h = new TestHelper("reif/rdr-00a", // testURI, + new TestHelper("reif/rdr-00a", // testURI, "reif/rdr-02a.rq",// queryFileURL "reif/empty.ttl",// dataFileURL "reif/rdr-02a.srx"// resultFileURL - ); + ).runTest(); - h.runTest(); + } + + /** + * Version of the above where the data are read from a file rather than being + * built up by hand. + */ + public void test_reificationDoneRight_00a_loadFromFile() throws Exception { + new TestHelper("reif/rdr-00a-loadFromFile", // testURI, + "reif/rdr-02a.rq",// queryFileURL + "reif/rdr-02.ttlx",// dataFileURL + "reif/rdr-02a.srx"// resultFileURL + ).runTest(); + } /** - * Simple query involving alice, bob, and an information extractor. + * Simple query involving alice, bob, and an information extractor. For this + * version of the test the data are modeled in the source file using RDF + * reification. * * <pre> * select ?src where { @@ -252,6 +279,29 @@ } + /** + * Simple query involving alice, bob, and an information extractor. For this + * version of the test the data are modeled in the source file using the RDR + * syntax. + * + * <pre> + * select ?src where { + * ?x foaf:name "Alice" . + * ?y foaf:name "Bob" . + * <<?x foaf:knows ?y>> dc:source ?src . + * } + * </pre> + */ + public void test_reificationDoneRight_01_usingRDRData() throws Exception { + + new TestHelper("reif/rdr-01-usingRDRData", // testURI, + "reif/rdr-01.rq",// queryFileURL + "reif/rdr-01.ttlx",// dataFileURL + "reif/rdr-01.srx"// resultFileURL + ).runTest(); + + } + /** * Same data, but the query uses the BIND() syntax and pulls out some more * information. @@ -277,6 +327,30 @@ } /** + * Same data, but the query uses the BIND() syntax and pulls out some more + * information and RDR syntax for the data. + * + * <pre> + * select ?who ?src ?conf where { + * ?x foaf:name "Alice" . + * ?y foaf:name ?who . + * BIND( <<?x foaf:knows ?y>> as ?sid ) . + * ?sid dc:source ?src . + * ?sid rv:confidence ?src . + * } + * </pre> + */ + public void test_reificationDoneRight_01a_usingRDRData() throws Exception { + + new TestHelper("reif/rdr-01a-usingRDRData", // testURI, + "reif/rdr-01a.rq",// queryFileURL + "reif/rdr-01.ttlx",// dataFileURL + "reif/rdr-01a.srx"// resultFileURL + ).runTest(); + + } + + /** * Simple query ("who bought sybase"). * * <pre> @@ -296,6 +370,25 @@ } /** + * Simple query ("who bought sybase") using RDR syntax for the data. + * + * <pre> + * SELECT ?src ?who { + * <<?who :bought :sybase>> dc:source ?src + * } + * </pre> + */ + public void test_reificationDoneRight_02_usingRDRData() throws Exception { + + new TestHelper("reif/rdr-02", // testURI, + "reif/rdr-02.rq",// queryFileURL + "reif/rdr-02.ttlx",// dataFileURL + "reif/rdr-02.srx"// resultFileURL + ).runTest(); + + } + + /** * Same data, but the query uses the BIND() syntax and pulls out some more * information. * @@ -318,7 +411,29 @@ } /** + * Same data, but the query uses the BIND() syntax and pulls out some more + * information and RDR syntax for the data. + * * <pre> + * SELECT ?src ?who ?created { + * BIND( <<?who :bought :sybase>> as ?sid ) . + * ?sid dc:source ?src . + * OPTIONAL {?sid dc:created ?created} + * } + * </pre> + */ + public void test_reificationDoneRight_02a_usingRDRData() throws Exception { + + new TestHelper("reif/rdr-02a", // testURI, + "reif/rdr-02a.rq",// queryFileURL + "reif/rdr-02a.ttlx",// dataFileURL + "reif/rdr-02a.srx"// resultFileURL + ).runTest(); + + } + + /** + * <pre> * prefix : <http://example.com/> * SELECT ?a { * BIND( <<?a :b :c>> AS ?ignored ) @@ -397,7 +512,7 @@ new TestHelper("reif/rdr-04", // testURI, "reif/rdr-04.rq",// queryFileURL - "reif/rdr-04.ttl",// dataFileURL + "reif/rdr-04.ttlx",// dataFileURL "reif/rdr-04.srx"// resultFileURL ).runTest(); Added: branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-01.ttlx =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-01.ttlx (rev 0) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-01.ttlx 2014-11-18 12:03:24 UTC (rev 8716) @@ -0,0 +1,77 @@ +@prefix foaf: <http://xmlns.com/foaf/0.1/> . +@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . +@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . +@prefix dc: <http://purl.org/dc/terms/> . +@prefix re: <http://reasoner.example.com/engines#> . +@prefix rr: <http://reasoner.example.com/rules#> . +@prefix rv: <http://reasoner.example.com/vocabulary#> . +@prefix xsd: <http://www.w3.org/2001/XMLSchema#> . +@prefix bd: <http://bigdata.com/RDF#> . + +bd:alice + rdf:type foaf:Person ; + foaf:name "Alice" ; + foaf:mbox <mailto:alice@work> ; + foaf:knows bd:bob. + +# The terse syntax: +<<bd:alice foaf:mbox <mailto:alice@work>>> + dc:source <http://hr.example.com/employees#bob> ; + dc:created "2012-02-05T12:34:00Z"^^xsd:dateTime . +# The expanded syntax. +#_:s1 rdf:subject bd:alice . +#_:s1 rdf:predicate foaf:mbox . +#_:s1 rdf:object <mailto:alice@work> . +#_:s1 rdf:type rdf:Statement . +#_:s1 dc:source <http://hr.example.com/employees#bob> ; +# dc:created "2012-02-05T12:34:00Z"^^xsd:dateTime . + +# Terse +<<bd:alice foaf:knows bd:bob>> + dc:source re:engine_1; + rv:rule rr:rule524 ; + rv:confidence 0.9835 . +# Expanded +#_:s2 rdf:subject bd:alice . +#_:s2 rdf:predicate foaf:knows . +#_:s2 rdf:object bd:bob . +#_:s2 rdf:type rdf:Statement . +#_:s2 +# dc:source re:engine_1; +# rv:rule rr:rule524 ; +# rv:confidence 0.9835 . + +bd:bob + rdf:type foaf:Person ; + foaf:name "Bob" ; + foaf:knows bd:alice ; + foaf:mbox <mailto:bob@work> ; + foaf:mbox <mailto:bob@home> . + +# Terse +<<bd:bob foaf:mbox <mailto:bob@home>>> + dc:creator <http://hr.example.com/infra/crawlers#we1> ; + dc:created "2012-02-05T12:34:00Z"^^xsd:dateTime ; + dc:source <http://whatever.nu/profile/bob1975> . +# Expanded +#_:s3 rdf:subject bd:bob . +#_:s3 rdf:predicate foaf:mbox . +#_:s3 rdf:object <mailto:bob@home> . +#_:s3 rdf:type rdf:Statement . +#_:s3 +# dc:creator <http://hr.example.com/infra/crawlers#we1> ; +# dc:created "2011-04-05T12:00:00Z"^^xsd:dateTime ; +# dc:source <http://whatever.nu/profile/bob1975> . + +# Terse +<<bd:bob foaf:mbox <mailto:bob@home>>> + dc:source <http://hr.example.com/employees/bob> ; + dc:created "2012-02-05T12:34:00Z"^^xsd:dateTime . +# Expanded +#_:s4 rdf:subject bd:bob . +#_:s4 rdf:predicate foaf:mbox . +#_:s4 rdf:object <mailto:bob@home> . +#_:s4 rdf:type rdf:Statement . +#_:s4 +# dc:source <http://hr.example.com/employees/bob> ; +# dc:created "2012-02-05T12:34:00Z"^^xsd:dateTime . Modified: branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02.ttl =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02.ttl 2014-11-17 22:11:08 UTC (rev 8715) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02.ttl 2014-11-18 12:03:24 UTC (rev 8716) @@ -1,6 +1,3 @@ -# <<:SAP :bought :sybase>> dc:source news:us-sybase ; -# dc:created "2011-04-05T12:00:00Z"^^xsd:dateTime . - @prefix : <http://example.com/> . @prefix news: <http://example.com/news/> . @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . @@ -8,6 +5,9 @@ @prefix dc: <http://purl.org/dc/terms/> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . +# <<:SAP :bought :sybase>> dc:source news:us-sybase ; +# dc:created "2011-04-05T12:00:00Z"^^xsd:dateTime . + :SAP :bought :sybase . _:s1 rdf:subject :SAP . _:s1 rdf:predicate :bought . Added: branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02.ttlx =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02.ttlx (rev 0) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02.ttlx 2014-11-18 12:03:24 UTC (rev 8716) @@ -0,0 +1,17 @@ +@prefix : <http://example.com/> . +@prefix news: <http://example.com/news/> . +@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . +@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . +@prefix dc: <http://purl.org/dc/terms/> . +@prefix xsd: <http://www.w3.org/2001/XMLSchema#> . + +<<:SAP :bought :sybase>> dc:source news:us-sybase ; + dc:created "2011-04-05T12:00:00Z"^^xsd:dateTime . + +#:SAP :bought :sybase . +#_:s1 rdf:subject :SAP . +#_:s1 rdf:predicate :bought . +#_:s1 rdf:object :sybase . +#_:s1 rdf:type rdf:Statement . +#_:s1 dc:source news:us-sybase . +#_:s1 dc:created "2011-04-05T12:00:00Z"^^xsd:dateTime . Added: branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02a.ttlx =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02a.ttlx (rev 0) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-02a.ttlx 2014-11-18 12:03:24 UTC (rev 8716) @@ -0,0 +1,17 @@ +@prefix : <http://example.com/> . +@prefix news: <http://example.com/news/> . +@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . +@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . +@prefix dc: <http://purl.org/dc/terms/> . +@prefix xsd: <http://www.w3.org/2001/XMLSchema#> . + +<<:SAP :bought :sybase>> dc:source news:us-sybase ; + dc:created "2011-04-05T12:00:00Z"^^xsd:dateTime . + +#:SAP :bought :sybase . +#_:s1 rdf:subject :SAP . +#_:s1 rdf:predicate :bought . +#_:s1 rdf:object :sybase . +#_:s1 rdf:type rdf:Statement . +#_:s1 dc:source news:us-sybase . +#_:s1 dc:created "2011-04-05T12:00:00Z"^^xsd:dateTime . Deleted: branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-04.ttl =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-04.ttl 2014-11-17 22:11:08 UTC (rev 8715) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-04.ttl 2014-11-18 12:03:24 UTC (rev 8716) @@ -1,7 +0,0 @@ -@prefix : <http://example.com/> . -@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . - -:a1 :b :c . -:a2 :b :c . -<<:a1 :b :c>> :d :e1 . -<<:a2 :b :c>> :d :e2 . Added: branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-04.ttlx =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-04.ttlx (rev 0) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-rdf/src/test/com/bigdata/rdf/sparql/ast/eval/reif/rdr-04.ttlx 2014-11-18 12:03:24 UTC (rev 8716) @@ -0,0 +1,7 @@ +@prefix : <http://example.com/> . +@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . + +:a1 :b :c . +:a2 :b :c . +<<:a1 :b :c>> :d :e1 . +<<:a2 :b :c>> :d :e2 . Modified: branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/TestProvenanceQuery.java =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/TestProvenanceQuery.java 2014-11-17 22:11:08 UTC (rev 8715) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/TestProvenanceQuery.java 2014-11-18 12:03:24 UTC (rev 8716) @@ -42,14 +42,13 @@ import org.openrdf.query.QueryLanguage; import org.openrdf.query.TupleQuery; import org.openrdf.query.TupleQueryResult; -import org.openrdf.query.algebra.evaluation.QueryBindingSet; -import org.openrdf.query.impl.DatasetImpl; import org.openrdf.rio.RDFFormat; import org.openrdf.rio.RDFWriter; import org.openrdf.rio.RDFWriterFactory; import org.openrdf.rio.RDFWriterRegistry; import org.openrdf.sail.SailConnection; +import com.bigdata.rdf.ServiceProviderHook; import com.bigdata.rdf.model.BigdataStatementImpl; import com.bigdata.rdf.store.BigdataStatementIterator; import com.bigdata.rdf.store.DataLoader; @@ -99,18 +98,17 @@ final DataLoader dataLoader = sail.database.getDataLoader(); dataLoader.loadData( - "bigdata-sails/src/test/com/bigdata/rdf/sail/provenance01.ttl", - ""/*baseURL*/, RDFFormat.TURTLE); + "bigdata-sails/src/test/com/bigdata/rdf/sail/provenance01.ttlx", + ""/*baseURL*/, ServiceProviderHook.TURTLE_RDR); } /* - * Serialize as RDF/XML using a vendor specific extension to represent - * the statement identifiers and statements about statements. + * Serialize as RDF/XML. * * Note: This is just for debugging. */ - { + if (log.isInfoEnabled()) { final BigdataStatementIterator itr = sail.database.getStatements(null, null, null); final String rdfXml; @@ -152,8 +150,7 @@ } // write the rdf/xml - if (log.isInfoEnabled()) - log.info(rdfXml); + log.info(rdfXml); } @@ -203,10 +200,10 @@ * Note: a [null] DataSet will cause context to be ignored when the * query is processed. */ - final DatasetImpl dataSet = null; //new DatasetImpl(); - - final BindingSet bindingSet = new QueryBindingSet(); - +// final DatasetImpl dataSet = null; //new DatasetImpl(); +// +// final BindingSet bindingSet = new QueryBindingSet(); +// // final CloseableIteration<? extends BindingSet, QueryEvaluationException> itr = conn // .evaluate(tupleExpr, dataSet, bindingSet, true/* includeInferred */); Modified: branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/TestSids.java =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/TestSids.java 2014-11-17 22:11:08 UTC (rev 8715) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/TestSids.java 2014-11-18 12:03:24 UTC (rev 8716) @@ -37,8 +37,8 @@ import org.openrdf.query.TupleQuery; import org.openrdf.query.TupleQueryResult; import org.openrdf.query.impl.BindingImpl; -import org.openrdf.rio.RDFFormat; +import com.bigdata.rdf.ServiceProviderHook; import com.bigdata.rdf.axioms.NoAxioms; import com.bigdata.rdf.model.BigdataBNode; import com.bigdata.rdf.model.BigdataStatement; @@ -98,7 +98,7 @@ cxn.setAutoCommit(false); - cxn.add(getClass().getResourceAsStream("sids.ttl"), "", RDFFormat.TURTLE); + cxn.add(getClass().getResourceAsStream("sids.ttl"), "", ServiceProviderHook.TURTLE_RDR); /* * Note: The either flush() or commit() is required to flush the @@ -118,7 +118,7 @@ // final String s = "http://localhost/host1"; // final String s = "http://localhost/switch1"; - String query = + final String query = "PREFIX myns: <http://mynamespace.com#> " + "SELECT distinct ?s ?p ?o " + " { " + @@ -138,7 +138,7 @@ log.info("no bindings"); } else { while (result.hasNext()) { - BindingSet bs = result.next(); + final BindingSet bs = result.next(); // log.info(bs.getBinding("s").getValue() + " " + bs.getBinding("p").getValue() + " " + bs.getBinding("o").getValue() + " ."); log.info((s == null ? bs.getBinding("s").getValue() : s) + " " + bs.getBinding("p").getValue() + " " + bs.getBinding("o").getValue() + " ."); } @@ -149,7 +149,7 @@ final TupleQueryResult result = tupleQuery.evaluate(); - Collection<BindingSet> solution = new LinkedList<BindingSet>(); + final Collection<BindingSet> solution = new LinkedList<BindingSet>(); solution.add(createBindingSet(new Binding[] { new BindingImpl("s", new URIImpl("http://localhost/host1")), new BindingImpl("p", new URIImpl("http://mynamespace.com#connectedTo")), Deleted: branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/provenance01.ttl =================================================================== (Binary files differ) Added: branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/provenance01.ttlx =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/provenance01.ttlx (rev 0) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/provenance01.ttlx 2014-11-18 12:03:24 UTC (rev 8716) @@ -0,0 +1,14 @@ +@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . +@prefix bd: <http://bigdata.com/RDF#> . +@prefix dc: <http://purl.org/dc/terms/> . +@prefix foo: <http://www.foo.org/> . + +foo:x rdf:type foo:A . +<<foo:x rdf:type foo:A>> dc:creator "bryan" . + +foo:y rdf:type foo:B . +<<foo:y rdf:type foo:B>> dc:creator "bryan" ; + dc:creator "mike" . + +foo:z rdf:type foo:C . +<<foo:z rdf:type foo:C>> dc:creator "mike" . \ No newline at end of file Modified: branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/tck/BigdataConnectionTest.java =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/tck/BigdataConnectionTest.java 2014-11-17 22:11:08 UTC (rev 8715) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/com/bigdata/rdf/sail/tck/BigdataConnectionTest.java 2014-11-18 12:03:24 UTC (rev 8716) @@ -33,33 +33,11 @@ */ package com.bigdata.rdf.sail.tck; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertNull; -import static org.junit.Assert.assertThat; -import static org.junit.Assert.assertTrue; -import static org.junit.Assert.fail; - import java.io.File; import java.io.IOException; -import java.lang.management.GarbageCollectorMXBean; -import java.lang.management.ManagementFactory; -import java.lang.reflect.Method; -import java.util.List; import java.util.Properties; import org.apache.log4j.Logger; -import org.openrdf.model.Statement; -import org.openrdf.model.Value; -import org.openrdf.model.vocabulary.RDFS; -import org.openrdf.query.BindingSet; -import org.openrdf.query.GraphQuery; -import org.openrdf.query.GraphQueryResult; -import org.openrdf.query.QueryInterruptedException; -import org.openrdf.query.QueryLanguage; -import org.openrdf.query.TupleQuery; -import org.openrdf.query.TupleQueryResult; import org.openrdf.repository.Repository; import org.openrdf.repository.RepositoryConnectionTest; @@ -72,7 +50,6 @@ import com.bigdata.rdf.sail.BigdataSail; import com.bigdata.rdf.sail.BigdataSail.Options; import com.bigdata.rdf.sail.BigdataSailRepository; -import com.bigdata.rdf.store.LocalTripleStore; /** * Bigdata uses snapshot isolation for transactions while openrdf assumes that Modified: branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/org/openrdf/repository/RepositoryConnectionTest.java =================================================================== --- branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/org/openrdf/repository/RepositoryConnectionTest.java 2014-11-17 22:11:08 UTC (rev 8715) +++ branches/BIGDATA_RELEASE_1_4_0/bigdata-sails/src/test/org/openrdf/repository/RepositoryConnectionTest.java 2014-11-18 12:03:24 UTC (rev 8716) @@ -1719,19 +1719,19 @@ } testCon.commit(); - TupleQuery query = testCon.prepareTupleQuery(QueryLanguage.SPARQL, + final TupleQuery query = testCon.prepareTupleQuery(QueryLanguage.SPARQL, "SELECT * WHERE { ?s ?p ?o . ?s1 ?p1 ?o1 . ?s2 ?p2 ?o2 . ?s3 ?p3 ?o3 } ORDER BY ?s1 ?p1 ?o1 LIMIT 1000"); query.setMaxQueryTime(2); - TupleQueryResult result = query.evaluate(); - long startTime = System.currentTimeMillis(); + final TupleQueryResult result = query.evaluate(); + final long startTime = System.currentTimeMillis(); try { result.hasNext(); fail("Query should have been interrupted"); } catch (QueryInterruptedException e) { // Expected - long duration = System.currentTimeMillis() - startTime; + final long duration = System.currentTimeMillis() - startTime; assertTrue("Query not interrupted quickly enough, should have been ~2s, but was " + (duration / 1000) + "s", duration < 5000); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |