You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@any23.apache.org by le...@apache.org on 2014/04/04 15:03:10 UTC

git commit: increase extracted triples to reflect improvements to WO and Programme vocabs, remove redundant triples.

Repository: any23
Updated Branches:
  refs/heads/master b2a33ff82 -> a3905bca1


increase extracted triples to reflect improvements to WO and Programme vocabs, remove redundant triples.


Project: http://git-wip-us.apache.org/repos/asf/any23/repo
Commit: http://git-wip-us.apache.org/repos/asf/any23/commit/a3905bca
Tree: http://git-wip-us.apache.org/repos/asf/any23/tree/a3905bca
Diff: http://git-wip-us.apache.org/repos/asf/any23/diff/a3905bca

Branch: refs/heads/master
Commit: a3905bca1fcb45064a087e0292ffd1e51e8ee748
Parents: b2a33ff
Author: Lewis John McGibbney <le...@apache.org>
Authored: Fri Apr 4 14:02:43 2014 +0100
Committer: Lewis John McGibbney <le...@apache.org>
Committed: Fri Apr 4 14:02:43 2014 +0100

----------------------------------------------------------------------
 .../org/apache/any23/extractor/rdf/JSONLDExtractorTest.java  | 8 +++-----
 .../test/java/org/apache/any23/vocab/RDFSchemaUtilsTest.java | 4 ++--
 test-resources/src/test/resources/cli/rover-test1.nq         | 2 --
 3 files changed, 5 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/any23/blob/a3905bca/core/src/test/java/org/apache/any23/extractor/rdf/JSONLDExtractorTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/any23/extractor/rdf/JSONLDExtractorTest.java b/core/src/test/java/org/apache/any23/extractor/rdf/JSONLDExtractorTest.java
index d6b42ea..759910e 100644
--- a/core/src/test/java/org/apache/any23/extractor/rdf/JSONLDExtractorTest.java
+++ b/core/src/test/java/org/apache/any23/extractor/rdf/JSONLDExtractorTest.java
@@ -25,12 +25,10 @@ import org.apache.any23.extractor.ExtractionParameters;
 import org.apache.any23.extractor.ExtractionResult;
 import org.apache.any23.extractor.ExtractionResultImpl;
 import org.apache.any23.rdf.RDFUtils;
-import org.apache.any23.writer.JSONWriter;
 import org.apache.any23.writer.RDFXMLWriter;
 import org.apache.any23.writer.TripleHandler;
 import org.apache.any23.writer.TripleHandlerException;
 import org.junit.After;
-import org.junit.Assert;
 import org.junit.Before;
 import org.junit.Ignore;
 import org.junit.Test;
@@ -59,7 +57,7 @@ public class JSONLDExtractorTest {
   }
 
   @Test
-  public void testExtractFromJSONLDDocuement() 
+  public void testExtractFromJSONLDDocument() 
     throws IOException, ExtractionException, TripleHandlerException {
       final URI uri = RDFUtils.uri("http://host.com/place-example.jsonld");
       extract(uri, "/org/apache/any23/extractor/rdf/place-example.jsonld");
@@ -76,8 +74,8 @@ public class JSONLDExtractorTest {
   public void extract(URI uri, String filePath) 
     throws IOException, ExtractionException, TripleHandlerException {
     ByteArrayOutputStream baos = new ByteArrayOutputStream();
-    final TripleHandler tHandler = new JSONWriter(baos);
-    final ExtractionContext extractionContext = new ExtractionContext("json-ld-extractor", uri);
+    final TripleHandler tHandler = new RDFXMLWriter(baos);
+    final ExtractionContext extractionContext = new ExtractionContext("rdf-jsonld", uri);
     final ExtractionResult result = new ExtractionResultImpl(extractionContext, extractor, tHandler);
     extractor.setStopAtFirstError(false);
     try {

http://git-wip-us.apache.org/repos/asf/any23/blob/a3905bca/core/src/test/java/org/apache/any23/vocab/RDFSchemaUtilsTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/any23/vocab/RDFSchemaUtilsTest.java b/core/src/test/java/org/apache/any23/vocab/RDFSchemaUtilsTest.java
index b0cbf85..3971191 100644
--- a/core/src/test/java/org/apache/any23/vocab/RDFSchemaUtilsTest.java
+++ b/core/src/test/java/org/apache/any23/vocab/RDFSchemaUtilsTest.java
@@ -43,7 +43,7 @@ public class RDFSchemaUtilsTest {
      */
     @Test
     public void testSerializeVocabulariesNTriples() {
-        serializeVocabularies(RDFFormat.NTRIPLES, 1622);
+        serializeVocabularies(RDFFormat.NTRIPLES, 1918);
     }
 
     /**
@@ -53,7 +53,7 @@ public class RDFSchemaUtilsTest {
      */
     @Test
     public void testSerializeVocabulariesRDFXML() {
-        serializeVocabularies(RDFFormat.RDFXML, 4241); // Effective lines + separators.
+        serializeVocabularies(RDFFormat.RDFXML, 4987); // Effective lines + separators.
     }
 
     private void serializeVocabularies(RDFFormat format, int expectedLines) {

http://git-wip-us.apache.org/repos/asf/any23/blob/a3905bca/test-resources/src/test/resources/cli/rover-test1.nq
----------------------------------------------------------------------
diff --git a/test-resources/src/test/resources/cli/rover-test1.nq b/test-resources/src/test/resources/cli/rover-test1.nq
index a49dfd8..1ee15d1 100644
--- a/test-resources/src/test/resources/cli/rover-test1.nq
+++ b/test-resources/src/test/resources/cli/rover-test1.nq
@@ -712,8 +712,6 @@
 <http://purl.org/ontology/wo/order> <http://www.w3.org/2000/01/rdf-schema#member> <http://purl.org/ontology/wo/> <http://purl.org/ontology/wo/> .
 <http://purl.org/ontology/wo/kingdomName> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/1999/02/22-rdf-syntax-ns#Property> <http://purl.org/ontology/wo/> .
 <http://purl.org/ontology/wo/kingdomName> <http://www.w3.org/2000/01/rdf-schema#member> <http://purl.org/ontology/wo/> <http://purl.org/ontology/wo/> .
-<http://purl.org/ontology/wo/divisionName> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/1999/02/22-rdf-syntax-ns#Property> <http://purl.org/ontology/wo/> .
-<http://purl.org/ontology/wo/divisionName> <http://www.w3.org/2000/01/rdf-schema#member> <http://purl.org/ontology/wo/> <http://purl.org/ontology/wo/> .
 <http://purl.org/ontology/wo/family> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/1999/02/22-rdf-syntax-ns#Property> <http://purl.org/ontology/wo/> .
 <http://purl.org/ontology/wo/family> <http://www.w3.org/2000/01/rdf-schema#member> <http://purl.org/ontology/wo/> <http://purl.org/ontology/wo/> .
 <http://purl.org/ontology/wo/phylumName> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/1999/02/22-rdf-syntax-ns#Property> <http://purl.org/ontology/wo/> .