You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@clerezza.apache.org by re...@apache.org on 2016/04/21 21:00:22 UTC

[5/5] clerezza git commit: updated versions fo tests, added NT test

updated versions fo tests, added NT test


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

Branch: refs/heads/master
Commit: b40fbfc5608bd06220afcfbc16f1c8da6ff4bdf4
Parents: 153270a
Author: Reto Gmür <re...@apache.org>
Authored: Thu Apr 21 20:58:24 2016 +0200
Committer: Reto Gmür <re...@apache.org>
Committed: Thu Apr 21 20:58:24 2016 +0200

----------------------------------------------------------------------
 provisioning/launchers/content-launcher/pom.xml |  6 ++---
 .../tests/content-launcher-tests/pom.xml        |  8 +++---
 .../integration/tests/UploadAndAccessTest.java  | 13 ++++++---
 .../tests/UploadAndAccessWithNTTest.java        | 28 ++++++++++++++++++++
 provisioning/rdf.tdb/pom.xml                    |  4 +--
 provisioning/rdf/pom.xml                        | 14 +++++-----
 releases/201604/pom.xml                         |  2 --
 7 files changed, 53 insertions(+), 22 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/clerezza/blob/b40fbfc5/provisioning/launchers/content-launcher/pom.xml
----------------------------------------------------------------------
diff --git a/provisioning/launchers/content-launcher/pom.xml b/provisioning/launchers/content-launcher/pom.xml
index 218ad62..bf76d82 100644
--- a/provisioning/launchers/content-launcher/pom.xml
+++ b/provisioning/launchers/content-launcher/pom.xml
@@ -24,7 +24,7 @@
     </parent>
     <groupId>org.apache.clerezza.provisioning</groupId>
     <artifactId>content-launcher</artifactId>
-    <version>1.0.1</version>
+    <version>1.0.2-SNAPSHOT</version>
     <packaging>jar</packaging>
 
     <name>Clerezza - Provisioning - Launchers - Content Launcher</name>
@@ -233,14 +233,14 @@
         <dependency>
             <groupId>org.apache.clerezza.provisioning</groupId>
             <artifactId>rdf</artifactId>
-            <version>1.1.0</version>
+            <version>1.1.1-SNAPSHOT</version>
             <type>partialbundlelist</type>
         </dependency>
 		
         <dependency>
             <groupId>org.apache.clerezza.provisioning</groupId>
             <artifactId>rdf.tdb</artifactId>
-            <version>1.1.0</version>
+            <version>1.1.1-SNAPSHOT</version>
             <type>partialbundlelist</type>
         </dependency>
 		 

http://git-wip-us.apache.org/repos/asf/clerezza/blob/b40fbfc5/provisioning/launchers/tests/content-launcher-tests/pom.xml
----------------------------------------------------------------------
diff --git a/provisioning/launchers/tests/content-launcher-tests/pom.xml b/provisioning/launchers/tests/content-launcher-tests/pom.xml
index 2364545..54897d1 100644
--- a/provisioning/launchers/tests/content-launcher-tests/pom.xml
+++ b/provisioning/launchers/tests/content-launcher-tests/pom.xml
@@ -117,7 +117,7 @@
         <dependency>
             <groupId>org.apache.clerezza.provisioning</groupId>
             <artifactId>content-launcher</artifactId>
-            <version>1.0.1</version>
+            <version>1.0.2-SNAPSHOT</version>
             <exclusions>
                 <exclusion>
                     <groupId>*</groupId>
@@ -152,7 +152,7 @@
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.core</artifactId>
-            <version>1.0.0</version>
+            <version>1.0.1-SNAPSHOT</version>
             <scope>test</scope>
         </dependency>
         <dependency>
@@ -164,13 +164,13 @@
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.jena.parser</artifactId>
-            <version>1.0.0</version>
+            <version>1.1.1-SNAPSHOT</version>
             <scope>runtime</scope>
         </dependency>
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.jena.serializer</artifactId>
-            <version>1.0.0</version>
+            <version>1.1.1-SNAPSHOT</version>
             <scope>runtime</scope>
         </dependency>
         <dependency>

http://git-wip-us.apache.org/repos/asf/clerezza/blob/b40fbfc5/provisioning/launchers/tests/content-launcher-tests/src/test/java/org/apache/clerezza/integration/tests/UploadAndAccessTest.java
----------------------------------------------------------------------
diff --git a/provisioning/launchers/tests/content-launcher-tests/src/test/java/org/apache/clerezza/integration/tests/UploadAndAccessTest.java b/provisioning/launchers/tests/content-launcher-tests/src/test/java/org/apache/clerezza/integration/tests/UploadAndAccessTest.java
index 6df1bc6..22f3c46 100644
--- a/provisioning/launchers/tests/content-launcher-tests/src/test/java/org/apache/clerezza/integration/tests/UploadAndAccessTest.java
+++ b/provisioning/launchers/tests/content-launcher-tests/src/test/java/org/apache/clerezza/integration/tests/UploadAndAccessTest.java
@@ -46,19 +46,24 @@ public class UploadAndAccessTest extends BaseTest {
     @Test
     public void uploadAndQuery() throws Exception {
         smallGraphTurtle = "<"+RestAssured.baseURI+"/test-resource> <http://www.w3.org/2000/01/rdf-schema#comment> \"A test resource\"^^<http://www.w3.org/2001/XMLSchema#string>.";
+        smallGraphTurtle += "<"+RestAssured.baseURI+"/test-resource> <http://www.w3.org/2000/01/rdf-schema#comment> \"Another comment\"@en.";
         smallGraph = Parser.getInstance().parse(new ByteArrayInputStream(smallGraphTurtle.getBytes("utf-8")), "text/turtle");
-        uploadTurtle();
+        uploadRDF();
         sparqlAsk();
         dereferenceResource();
     }
     
-    protected void uploadTurtle() {
+    protected byte[] getSerializedRdfToUpload() {
         ByteArrayOutputStream baos = new ByteArrayOutputStream();
         Serializer.getInstance().serialize(baos, smallGraph, getRdfFormat());
+        return baos.toByteArray();
+    }
+    
+    protected void uploadRDF() { 
         RestAssured.given().header("Accept", "text/html")
                 .auth().basic("admin", "admin")
                 .formParam("name", Constants.CONTENT_GRAPH_URI_STRING)
-                .multiPart("graph", "test.ttl", baos.toByteArray(), getRdfFormat())
+                .multiPart("graph", "test.ttl", getSerializedRdfToUpload(), getRdfFormat())
                 .formParam("append", "Append")
                 .expect().statusCode(HttpStatus.SC_NO_CONTENT).when()
                 .post("/graph");
@@ -87,7 +92,7 @@ public class UploadAndAccessTest extends BaseTest {
                 .when()
                 .get("/test-resource");
         ImmutableGraph returnedGraph = Parser.getInstance().parse(response.getBody().asInputStream(), getRdfFormat());
-        Assert.assertEquals("Returned Graph has wrong size", 1, returnedGraph.size());
+        Assert.assertEquals("Returned Graph has wrong size", 2, returnedGraph.size());
         Assert.assertEquals(smallGraph, returnedGraph);
     }
     

http://git-wip-us.apache.org/repos/asf/clerezza/blob/b40fbfc5/provisioning/launchers/tests/content-launcher-tests/src/test/java/org/apache/clerezza/integration/tests/UploadAndAccessWithNTTest.java
----------------------------------------------------------------------
diff --git a/provisioning/launchers/tests/content-launcher-tests/src/test/java/org/apache/clerezza/integration/tests/UploadAndAccessWithNTTest.java b/provisioning/launchers/tests/content-launcher-tests/src/test/java/org/apache/clerezza/integration/tests/UploadAndAccessWithNTTest.java
new file mode 100644
index 0000000..f644127
--- /dev/null
+++ b/provisioning/launchers/tests/content-launcher-tests/src/test/java/org/apache/clerezza/integration/tests/UploadAndAccessWithNTTest.java
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2015 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.clerezza.integration.tests;
+
+/**
+ *
+ * @author reto
+ */
+public class UploadAndAccessWithNTTest extends UploadAndAccessTest {
+    @Override
+    protected String getRdfFormat() {
+        return "application/n-triples";        
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/clerezza/blob/b40fbfc5/provisioning/rdf.tdb/pom.xml
----------------------------------------------------------------------
diff --git a/provisioning/rdf.tdb/pom.xml b/provisioning/rdf.tdb/pom.xml
index 38be7ca..79ba36a 100644
--- a/provisioning/rdf.tdb/pom.xml
+++ b/provisioning/rdf.tdb/pom.xml
@@ -31,7 +31,7 @@
     
     <groupId>org.apache.clerezza.provisioning</groupId>
     <artifactId>rdf.tdb</artifactId>
-    <version>1.1.0</version>
+    <version>1.1.1-SNAPSHOT</version>
     <packaging>feature</packaging>
 
     <name>Clerezza - Provisioning - Jena TDB Storage</name>
@@ -46,7 +46,7 @@
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.jena.tdb.storage</artifactId>
-            <version>1.1.0</version>
+            <version>1.1.1-SNAPSHOT</version>
         </dependency>
 
 

http://git-wip-us.apache.org/repos/asf/clerezza/blob/b40fbfc5/provisioning/rdf/pom.xml
----------------------------------------------------------------------
diff --git a/provisioning/rdf/pom.xml b/provisioning/rdf/pom.xml
index 7799343..87159f5 100644
--- a/provisioning/rdf/pom.xml
+++ b/provisioning/rdf/pom.xml
@@ -31,7 +31,7 @@
     
     <groupId>org.apache.clerezza.provisioning</groupId>
     <artifactId>rdf</artifactId>
-    <version>1.1.0</version>
+    <version>1.1.1-SNAPSHOT</version>
     <packaging>feature</packaging>
 
     <name>Clerezza - Provisioning - RDF</name>
@@ -124,12 +124,12 @@
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.jena.commons</artifactId>
-            <version>1.1.0</version>
+            <version>1.1.1-SNAPSHOT</version>
         </dependency>
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.jena.facade</artifactId>
-            <version>1.1.0</version>
+            <version>1.1.1-SNAPSHOT</version>
         </dependency>
         <!-- requirws an older version jena-iri
         <dependency>
@@ -150,22 +150,22 @@
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.jena.serializer</artifactId>
-            <version>1.1.0</version>
+            <version>1.1.1-SNAPSHOT</version>
         </dependency>
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.jena.parser</artifactId>
-            <version>1.1.0</version>
+            <version>1.1.1-SNAPSHOT</version>
         </dependency>
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.jena.sparql</artifactId>
-            <version>1.1.0</version>
+            <version>1.1.1-SNAPSHOT</version>
         </dependency>
         <dependency>
             <groupId>org.apache.clerezza</groupId>
             <artifactId>rdf.jena.storage</artifactId>
-            <version>1.1.0</version>
+            <version>1.1.1-SNAPSHOT</version>
         </dependency>
         <!-- <dependency>
             <groupId>org.apache.clerezza</groupId>

http://git-wip-us.apache.org/repos/asf/clerezza/blob/b40fbfc5/releases/201604/pom.xml
----------------------------------------------------------------------
diff --git a/releases/201604/pom.xml b/releases/201604/pom.xml
index 2e36f79..4a95cbe 100644
--- a/releases/201604/pom.xml
+++ b/releases/201604/pom.xml
@@ -51,8 +51,6 @@
         <module>../../rdf/jena/storage</module>
         <module>../../rdf/jena/tdb.storage</module>
         <module>../../rdf/core</module>
-        <!-- this is not yet used in launcher (as it needs to be listed inthe feature.xml -->
-        <module>../../provisioning/jaxrs-whiteboard</module>
         <module>../../provisioning/rdf</module>
         <module>../../provisioning/launchers/content-launcher</module>
         <module>../../provisioning/launchers/linked-data-launcher</module>