[jboss-osgi-commits] JBoss-OSGI SVN: r95622 - in projects/jboss-osgi/trunk: reactor/jta/src and 8 other directories.

jboss-osgi-commits at lists.jboss.org jboss-osgi-commits at lists.jboss.org
Tue Oct 27 13:39:02 EDT 2009


Author: thomas.diesler at jboss.com
Date: 2009-10-27 13:39:01 -0400 (Tue, 27 Oct 2009)
New Revision: 95622

Added:
   projects/jboss-osgi/trunk/reactor/jta/src/test/
   projects/jboss-osgi/trunk/reactor/jta/src/test/java/
   projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/
   projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/
   projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/
   projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/
   projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/
   projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/TransactionManagerTestCase.java
   projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/UserTransactionTestCase.java
Modified:
   projects/jboss-osgi/trunk/reactor/jta/.classpath
   projects/jboss-osgi/trunk/reactor/jta/pom.xml
   projects/jboss-osgi/trunk/testsuite/example/src/test/java/org/jboss/test/osgi/example/webapp/WebAppInterceptorTestCase.java
Log:
Add basic JTA bootstrap tests

Modified: projects/jboss-osgi/trunk/reactor/jta/.classpath
===================================================================
--- projects/jboss-osgi/trunk/reactor/jta/.classpath	2009-10-27 17:26:51 UTC (rev 95621)
+++ projects/jboss-osgi/trunk/reactor/jta/.classpath	2009-10-27 17:39:01 UTC (rev 95622)
@@ -1,6 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <classpath>
 	<classpathentry kind="src" output="target/classes" path="src/main/java"/>
+	<classpathentry kind="src" path="src/test/java"/>
 	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
 	<classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
 	<classpathentry kind="output" path="target/classes"/>

Modified: projects/jboss-osgi/trunk/reactor/jta/pom.xml
===================================================================
--- projects/jboss-osgi/trunk/reactor/jta/pom.xml	2009-10-27 17:26:51 UTC (rev 95621)
+++ projects/jboss-osgi/trunk/reactor/jta/pom.xml	2009-10-27 17:39:01 UTC (rev 95622)
@@ -69,6 +69,18 @@
       <artifactId>org.osgi.compendium</artifactId>
       <scope>provided</scope>
     </dependency>
+    
+    <!-- Test Dependecies -->
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.slf4j</groupId>
+      <artifactId>slf4j-log4j12</artifactId>
+      <scope>test</scope>
+    </dependency>
   </dependencies>
 
   <build>

Added: projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/TransactionManagerTestCase.java
===================================================================
--- projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/TransactionManagerTestCase.java	                        (rev 0)
+++ projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/TransactionManagerTestCase.java	2009-10-27 17:39:01 UTC (rev 95622)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.osgi.jta;
+
+//$Id$
+
+import static org.junit.Assert.*;
+
+import javax.transaction.TransactionManager;
+
+import org.junit.Test;
+
+/**
+ * Test basic JBossTM operations
+ * 
+ * @author thomas.diesler at jboss.com
+ * @since 19-Oct-2009
+ */
+public class TransactionManagerTestCase
+{
+   @Test
+   public void testTransactionManagerBootstrap()
+   {
+      TransactionManager tm = com.arjuna.ats.jta.TransactionManager.transactionManager();
+      assertNotNull("TransactionManager not null", tm);
+   }
+}


Property changes on: projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/TransactionManagerTestCase.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/UserTransactionTestCase.java
===================================================================
--- projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/UserTransactionTestCase.java	                        (rev 0)
+++ projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/UserTransactionTestCase.java	2009-10-27 17:39:01 UTC (rev 95622)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.osgi.jta;
+
+//$Id$
+
+import static org.junit.Assert.assertNotNull;
+
+import javax.transaction.UserTransaction;
+
+import org.junit.Test;
+
+/**
+ * Test basic JBossTM operations
+ * 
+ * @author thomas.diesler at jboss.com
+ * @since 19-Oct-2009
+ */
+public class UserTransactionTestCase
+{
+   @Test
+   public void testUserTransactionBootstrap()
+   {
+      UserTransaction ut = com.arjuna.ats.jta.UserTransaction.userTransaction();
+      assertNotNull("UserTransaction not null", ut);
+   }
+}


Property changes on: projects/jboss-osgi/trunk/reactor/jta/src/test/java/org/jboss/test/osgi/jta/UserTransactionTestCase.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: projects/jboss-osgi/trunk/testsuite/example/src/test/java/org/jboss/test/osgi/example/webapp/WebAppInterceptorTestCase.java
===================================================================
--- projects/jboss-osgi/trunk/testsuite/example/src/test/java/org/jboss/test/osgi/example/webapp/WebAppInterceptorTestCase.java	2009-10-27 17:26:51 UTC (rev 95621)
+++ projects/jboss-osgi/trunk/testsuite/example/src/test/java/org/jboss/test/osgi/example/webapp/WebAppInterceptorTestCase.java	2009-10-27 17:39:01 UTC (rev 95622)
@@ -66,21 +66,21 @@
    public void testResourceAccess() throws Exception
    {
       // FIXME: http://issues.ops4j.org/browse/PAXWEB-182
-      String line = getHttpResponse("/message.txt", 30000);
+      String line = getHttpResponse("/message.txt", 20000);
       assertEquals("Hello from Resource", line);
    }
 
    @Test
    public void testServletAccess() throws Exception
    {
-      String line = getHttpResponse("/servlet?test=plain");
+      String line = getHttpResponse("/servlet?test=plain", 20000);
       assertEquals("Hello from Servlet", line);
    }
 
    @Test
    public void testServletInitProps() throws Exception
    {
-      String line = getHttpResponse("/servlet?test=initProp");
+      String line = getHttpResponse("/servlet?test=initProp", 20000);
       assertEquals("initProp=SomeValue", line);
    }
 }
\ No newline at end of file



More information about the jboss-osgi-commits mailing list