[JBoss-dev] CVS update: jbosstest/src/main/org/jboss/test/jrmp/test TestCustomSockets.java TestDynLoading.java

2001-07-09 Thread Jason Dillon

  User: user57  
  Date: 01/07/09 19:34:04

  Modified:src/main/org/jboss/test/jrmp/test TestCustomSockets.java
TestDynLoading.java
  Log:
   o changed all deploy tests to deploy as a test and to not call System.exit().
 this should allow reports to be generated for tests that fail to deploy.
   o modified run_tests.xml basic-security-tests to not-halt on error, so that
 test-and-report will produce reports even if the security tests fail.
  
  Revision  ChangesPath
  1.4   +17 -20
jbosstest/src/main/org/jboss/test/jrmp/test/TestCustomSockets.java
  
  Index: TestCustomSockets.java
  ===
  RCS file: 
/cvsroot/jboss/jbosstest/src/main/org/jboss/test/jrmp/test/TestCustomSockets.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- TestCustomSockets.java2001/07/06 02:29:20 1.3
  +++ TestCustomSockets.java2001/07/10 02:34:04 1.4
  @@ -18,7 +18,7 @@
   container invoker.
   
   @author [EMAIL PROTECTED]
  -@version $Revision: 1.3 $
  +@version $Revision: 1.4 $
   */
   public class TestCustomSockets extends junit.framework.TestCase
   {
  @@ -61,24 +61,21 @@
   bean.remove();
   }
   
  -public static Test suite() {
  -TestSuite suite = new TestSuite();
  - 
  -try {
  -String filename = ../deploy/jrmp-comp.jar;
  -System.out.println(Deploying...);
  -Deploy.deploy(filename);
  +   /**
  +* Setup the test suite.
  +*/
  +   public static Test suite() {
  +  TestSuite suite = new TestSuite();
  +
  +  // add a test case to deploy our support applications
  +  String filename = jrmp-comp.jar;
  +  suite.addTest(new Deploy.Deployer(filename));
  +
  +  suite.addTest(new TestSuite(TestCustomSockets.class));
  +  
  +  // add a test case to undeploy our support applications
  +  suite.addTest(new Deploy.Undeployer(filename));
   
  -suite.addTest(new TestSuite(TestCustomSockets.class));
  -
  -// add a test case to undeploy our support applications
  -suite.addTest(new Deploy.Undeployer(filename));
  -}
  -catch (Throwable t) {
  -t.printStackTrace();
  -System.exit(0);
  -}
  -
  -return suite;
  -}
  +  return suite;
  +   }
   }
  
  
  
  1.3   +45 -48jbosstest/src/main/org/jboss/test/jrmp/test/TestDynLoading.java
  
  Index: TestDynLoading.java
  ===
  RCS file: 
/cvsroot/jboss/jbosstest/src/main/org/jboss/test/jrmp/test/TestDynLoading.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- TestDynLoading.java   2001/07/06 02:29:20 1.2
  +++ TestDynLoading.java   2001/07/10 02:34:04 1.3
  @@ -19,56 +19,53 @@
   /** Test of RMI dynamic class loading.
   
   @author [EMAIL PROTECTED]
  -@version $Revision: 1.2 $
  +@version $Revision: 1.3 $
   */
  -public class TestDynLoading extends junit.framework.TestCase
  +public class TestDynLoading
  +   extends TestCase
   {
  -public TestDynLoading(String name)
  -{
  -super(name);
  -System.out.println(TestDynLoading);
  -}
  -
  -protected void setUp() throws Exception
  -{
  -// System.out.println(TestDynLoading.setup(jrmp-dl.jar));
  -// Deploy.deploy(jrmp-dl.jar);
  -}
  -
  -public void testAccess() throws Exception
  -{
  -InitialContext jndiContext = new InitialContext();
  -System.out.println(Lookup StatefulSession);
  -Object obj = jndiContext.lookup(StatefulSession);
  -StatelessSessionHome home = (StatelessSessionHome) obj;
  -System.out.println(Found StatefulSession Home);
  -StatelessSession bean = home.create();
  -System.out.println(Created StatefulSession);
  -IString echo = bean.copy(jrmp-dl);
  -System.out.println(bean.copy(jrmp-dl) = +echo);
  -System.out.println(IString.class = +echo.getClass());
  -bean.remove();
  -}
  -
  -public static Test suite() {
  -TestSuite suite = new TestSuite();
  - 
  -try {
  -String filename = ../deploy/jrmp-dl.jar;
  -System.out.println(Deploying...);
  -Deploy.deploy(filename);
  -
  -suite.addTest(new TestSuite(TestDynLoading.class));
  -
  -// add a test case to undeploy our support applications
  -suite.addTest(new Deploy.Undeployer(filename));
  -}
  -catch (Throwable t) {
  -t.printStackTrace();
  -System.exit(0);
  -}
  +   public TestDynLoading(String name)
  +   {
  +  super(name);
  +  System.out.println(TestDynLoading);
  +   }
  +
  +   protected void setUp() throws Exception
  +   {
  +  // 

[JBoss-dev] CVS update: jbosstest/src/main/org/jboss/test/jrmp/test TestCustomSockets.java TestDynLoading.java

2001-07-05 Thread Jason Dillon

  User: user57  
  Date: 01/07/05 19:29:20

  Modified:src/main/org/jboss/test/jrmp/test TestCustomSockets.java
TestDynLoading.java
  Log:
   o Changed all tests which deploy one or more jars to undeploy after
 testing.
  
  Revision  ChangesPath
  1.3   +26 -2 
jbosstest/src/main/org/jboss/test/jrmp/test/TestCustomSockets.java
  
  Index: TestCustomSockets.java
  ===
  RCS file: 
/cvsroot/jboss/jbosstest/src/main/org/jboss/test/jrmp/test/TestCustomSockets.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- TestCustomSockets.java2001/06/19 02:50:28 1.2
  +++ TestCustomSockets.java2001/07/06 02:29:20 1.3
  @@ -6,6 +6,10 @@
   import javax.naming.InitialContext;
   import javax.naming.NamingException;
   
  +import junit.framework.Test;
  +import junit.framework.TestCase;
  +import junit.framework.TestSuite;
  +
   import org.jboss.test.jrmp.interfaces.StatelessSession;
   import org.jboss.test.jrmp.interfaces.StatelessSessionHome;
   import org.jboss.test.util.Deploy;
  @@ -14,7 +18,7 @@
   container invoker.
   
   @author [EMAIL PROTECTED]
  -@version $Revision: 1.2 $
  +@version $Revision: 1.3 $
   */
   public class TestCustomSockets extends junit.framework.TestCase
   {
  @@ -25,7 +29,7 @@
   
   protected void setUp() throws Exception
   {
  -Deploy.deploy(jrmp-comp.jar);
  +// Deploy.deploy(jrmp-comp.jar);
   }
   
   public void testCustomAccess() throws Exception
  @@ -57,4 +61,24 @@
   bean.remove();
   }
   
  +public static Test suite() {
  +TestSuite suite = new TestSuite();
  + 
  +try {
  +String filename = ../deploy/jrmp-comp.jar;
  +System.out.println(Deploying...);
  +Deploy.deploy(filename);
  +
  +suite.addTest(new TestSuite(TestCustomSockets.class));
  +
  +// add a test case to undeploy our support applications
  +suite.addTest(new Deploy.Undeployer(filename));
  +}
  +catch (Throwable t) {
  +t.printStackTrace();
  +System.exit(0);
  +}
  +
  +return suite;
  +}
   }
  
  
  
  1.2   +28 -2 jbosstest/src/main/org/jboss/test/jrmp/test/TestDynLoading.java
  
  Index: TestDynLoading.java
  ===
  RCS file: 
/cvsroot/jboss/jbosstest/src/main/org/jboss/test/jrmp/test/TestDynLoading.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- TestDynLoading.java   2001/06/19 02:50:28 1.1
  +++ TestDynLoading.java   2001/07/06 02:29:20 1.2
  @@ -6,15 +6,20 @@
   import javax.naming.InitialContext;
   import javax.naming.NamingException;
   
  +import junit.framework.Test;
  +import junit.framework.TestCase;
  +import junit.framework.TestSuite;
  +
   import org.jboss.test.jrmp.interfaces.IString;
   import org.jboss.test.jrmp.interfaces.StatelessSession;
   import org.jboss.test.jrmp.interfaces.StatelessSessionHome;
  +
   import org.jboss.test.util.Deploy;
   
   /** Test of RMI dynamic class loading.
   
   @author [EMAIL PROTECTED]
  -@version $Revision: 1.1 $
  +@version $Revision: 1.2 $
   */
   public class TestDynLoading extends junit.framework.TestCase
   {
  @@ -26,8 +31,8 @@
   
   protected void setUp() throws Exception
   {
  -System.out.println(TestDynLoading.setup(jrmp-dl.jar));
  -Deploy.deploy(jrmp-dl.jar);
  +// System.out.println(TestDynLoading.setup(jrmp-dl.jar));
  +// Deploy.deploy(jrmp-dl.jar);
   }
   
   public void testAccess() throws Exception
  @@ -43,6 +48,27 @@
   System.out.println(bean.copy(jrmp-dl) = +echo);
   System.out.println(IString.class = +echo.getClass());
   bean.remove();
  +}
  +
  +public static Test suite() {
  +TestSuite suite = new TestSuite();
  + 
  +try {
  +String filename = ../deploy/jrmp-dl.jar;
  +System.out.println(Deploying...);
  +Deploy.deploy(filename);
  +
  +suite.addTest(new TestSuite(TestDynLoading.class));
  +
  +// add a test case to undeploy our support applications
  +suite.addTest(new Deploy.Undeployer(filename));
  +}
  +catch (Throwable t) {
  +t.printStackTrace();
  +System.exit(0);
  +}
  +
  +return suite;
   }
   
   }
  
  
  

___
Jboss-development mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-development