You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by gr...@apache.org on 2015/02/26 19:18:59 UTC

[26/50] [abbrv] incubator-usergrid git commit: Add jackson-xc back in.

Add jackson-xc back in.


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

Branch: refs/heads/USERGRID-280
Commit: fe5ea330fdeb563b8ddc06bb22eafa1a46617498
Parents: f20c353
Author: Dave Johnson <dm...@apigee.com>
Authored: Wed Feb 25 10:07:14 2015 -0500
Committer: Dave Johnson <dm...@apigee.com>
Committed: Wed Feb 25 10:07:14 2015 -0500

----------------------------------------------------------------------
 stack/rest/pom.xml                              | 41 +++++++-------------
 .../resources/usergrid-rest-deploy-context.xml  |  2 +-
 .../org/apache/usergrid/rest/SimplestTest.java  | 35 +++++++++++++++++
 .../org/apache/usergrid/rest/TomcatRuntime.java |  4 +-
 4 files changed, 53 insertions(+), 29 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/fe5ea330/stack/rest/pom.xml
----------------------------------------------------------------------
diff --git a/stack/rest/pom.xml b/stack/rest/pom.xml
index 70072d9..3a6c0de 100644
--- a/stack/rest/pom.xml
+++ b/stack/rest/pom.xml
@@ -105,29 +105,12 @@
                     <forkCount>1</forkCount>
                     <threadCount>${usergrid.rest.threads}</threadCount>
                     <reuseForks>true</reuseForks>
-                    <argLine>-Dtest.barrier.timestamp=${maven.build.timestamp} -Dtest.clean.storage=true -Xmx${ug.heapmax} -Xms${ug.heapmin} -Dfile.encoding=UTF-8 -Dsun.jnu.encoding=UTF-8 -javaagent:${settings.localRepository}/com/github/stephenc/jamm/0.2.5/jamm-0.2.5.jar ${ug.argline}
+                    <argLine>-Dwebapp.directory=${basedir}/src/main/webapp -Dtest.barrier.timestamp=${maven.build.timestamp} -Dtest.clean.storage=true -Xmx${ug.heapmax} -Xms${ug.heapmin} -Dfile.encoding=UTF-8 -Dsun.jnu.encoding=UTF-8 -javaagent:${settings.localRepository}/com/github/stephenc/jamm/0.2.5/jamm-0.2.5.jar ${ug.argline}
                     </argLine>
                     <includes>
-
                         <include>**/*IT.java</include>
                         <include>**/*Test.java</include>
-
-                        <!-- how many tests can we run before Tomcat JVM throws OOM / PermGen exceptions -->
-
-                        <!--<include>**/org/apache/usergrid/rest/BasicIT.java</include>-->
-                        <!--<include>**/org/apache/usergrid/rest/PartialUpdateTest.java</include>-->
-                        <!--<include>**/org/apache/usergrid/rest/applications/collection/**/CollectionsResourceIT.java</include>-->
-
-                        <!--<include>**/org/apache/usergrid/rest/*IT.java</include>-->
-                        <!--<include>**/org/apache/usergrid/rest/*Test.java</include>-->
-
-                        <!--<include>**/org/apache/usergrid/rest/management/**/*IT.java</include>-->
-                        <!--<include>**/org/apache/usergrid/rest/management/**/*Test.java</include>-->
-
-                        <!--<include>**/org/apache/usergrid/rest/applications/collection/**/*IT.java</include>-->
-                        <!--<include>**/org/apache/usergrid/rest/applications/collection/**/*Test.java</include>-->
-
-                    </includes>
+                   </includes>
 
                 </configuration>
 
@@ -358,6 +341,12 @@
             <groupId>org.jvnet.mock-javamail</groupId>
             <artifactId>mock-javamail</artifactId>
             <scope>test</scope>
+            <exclusions>
+                <exclusion>
+                    <artifactId>mail</artifactId>
+                    <groupId>javax.mail</groupId>
+                </exclusion>
+            </exclusions>
         </dependency>
 
         <dependency>
@@ -366,14 +355,14 @@
             <scope>test</scope>
         </dependency>
 
-        <!-- Arquillian deps -->
+        <dependency>
+            <groupId>org.codehaus.jackson</groupId>
+            <artifactId>jackson-xc</artifactId>
+            <version>${jackson-version}</version>
+            <scope>test</scope>
+        </dependency>
 
-        <!--<dependency>-->
-            <!--<groupId>org.codehaus.jackson</groupId>-->
-            <!--<artifactId>jackson-xc</artifactId>-->
-            <!--<version>${jackson-version}</version>-->
-            <!--<scope>test</scope>-->
-        <!--</dependency>-->
+        <!-- Arquillian deps -->
 
         <!--<dependency>-->
             <!--<groupId>org.jboss.arquillian</groupId>-->

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/fe5ea330/stack/rest/src/main/resources/usergrid-rest-deploy-context.xml
----------------------------------------------------------------------
diff --git a/stack/rest/src/main/resources/usergrid-rest-deploy-context.xml b/stack/rest/src/main/resources/usergrid-rest-deploy-context.xml
index d240231..9965dbc 100644
--- a/stack/rest/src/main/resources/usergrid-rest-deploy-context.xml
+++ b/stack/rest/src/main/resources/usergrid-rest-deploy-context.xml
@@ -33,7 +33,7 @@
 		<property name="locations">
 			<list>
 				<value>classpath:/usergrid-default.properties</value>
-                <value>classpath:/usergrid-deployment.properties</value>
+                <value>${usergrid-custom-spring-properties}</value>
 			</list>
 		</property>
 	</bean>

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/fe5ea330/stack/rest/src/test/java/org/apache/usergrid/rest/SimplestTest.java
----------------------------------------------------------------------
diff --git a/stack/rest/src/test/java/org/apache/usergrid/rest/SimplestTest.java b/stack/rest/src/test/java/org/apache/usergrid/rest/SimplestTest.java
new file mode 100644
index 0000000..6703c1b
--- /dev/null
+++ b/stack/rest/src/test/java/org/apache/usergrid/rest/SimplestTest.java
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.usergrid.rest;
+
+import org.junit.Test;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import static org.junit.Assert.assertNotNull;
+
+/**
+ * Simplest test verifies if REST test infrastructure is functioning.
+ */
+public class SimplestTest extends org.apache.usergrid.rest.test.resource2point0.AbstractRestIT {
+    private static final Logger log = LoggerFactory.getLogger(SimplestTest.class);
+
+    @Test
+    public void getGetToken() {
+        assertNotNull( getAdminToken() );
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/fe5ea330/stack/rest/src/test/java/org/apache/usergrid/rest/TomcatRuntime.java
----------------------------------------------------------------------
diff --git a/stack/rest/src/test/java/org/apache/usergrid/rest/TomcatRuntime.java b/stack/rest/src/test/java/org/apache/usergrid/rest/TomcatRuntime.java
index ab22450..498068a 100644
--- a/stack/rest/src/test/java/org/apache/usergrid/rest/TomcatRuntime.java
+++ b/stack/rest/src/test/java/org/apache/usergrid/rest/TomcatRuntime.java
@@ -42,7 +42,7 @@ public class TomcatRuntime extends ExternalResource {
     private static final Logger log = LoggerFactory.getLogger( TomcatRuntime.class );
 
 
-    private static final String WEBAPPS_PATH = "src/main/webapp";
+    private static final String WEBAPP_PATH = System.getProperty("webapp.directory");
 
     private static TomcatRuntime instance;
 
@@ -54,7 +54,7 @@ public class TomcatRuntime extends ExternalResource {
         //before we run tomcat, we need to cleanup our data
         ConcurrentProcessSingleton.getInstance();
 
-        tomcat = new TomcatInstance( WEBAPPS_PATH );
+        tomcat = new TomcatInstance( WEBAPP_PATH );
         tomcat.startTomcat();
 
         //stop on JVM shutdown