axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Roder <mro...@wamnet.com>
Subject RE: cvs commit: xml-axis/java/test/multiref Main.java
Date Wed, 07 Nov 2001 15:57:56 GMT

I think your Main.java should have the code moved into the MutliRefTestCase.
Each test then could be its own method and just use this.asserts and
this.fail for any testing of conditions and notice of failures.

It looks like you wrote a main method that did all of the tests and then
wrapped junit around that.  A better way might be to write each test case in
junit and then just have a little main method that calls those by hand if
you want to be able to run it from the command line.

Later

Mark


-----Original Message-----
From: scheu@apache.org [mailto:scheu@apache.org]
Sent: Wednesday, November 07, 2001 9:35 AM
To: xml-axis-cvs@apache.org
Subject: cvs commit: xml-axis/java/test/multiref Main.java


scheu       01/11/07 07:35:06

  Modified:    java/test/multiref Main.java
  Log:
  Commented out all of the "Passed test..." messages.
  Messages are only printed if the test fails.
  
  Revision  Changes    Path
  1.2       +14 -14    xml-axis/java/test/multiref/Main.java
  
  Index: Main.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/test/multiref/Main.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- Main.java	2001/11/06 21:41:55	1.1
  +++ Main.java	2001/11/07 15:35:06	1.2
  @@ -89,7 +89,7 @@
           // Test for simple tree
           int rc = remoteTest.testSimpleTree(holder);
           if (rc == 0) {
  -            System.err.println("Passed testSimpleTree 1");
  +            // System.err.println("Passed testSimpleTree 1");
           } else {
               System.err.println("Failed testSimpleTree 1");
               throw new Exception("Failed testSimpleTree 1 with "+rc);
  @@ -98,7 +98,7 @@
           // invoke the test again!
           rc = remoteTest.testSimpleTree(holder);
           if (rc == 0) {
  -            System.err.println("Passed testSimpleTree 2");
  +            // System.err.println("Passed testSimpleTree 2");
           } else {
               System.err.println("Failed testSimpleTree 2");
               throw new Exception("Failed testSimpleTree 2 with "+rc);
  @@ -115,7 +115,7 @@
           // Test for a diamond
           rc = remoteTest.testDiamond(holder);
           if (rc == 0) {
  -            System.err.println("Passed testDiamond 1");
  +            // System.err.println("Passed testDiamond 1");
           } else {
               System.err.println("Failed testDiamond 1");
               throw new Exception("Failed testDiamond 1 with "+rc);
  @@ -124,7 +124,7 @@
           // invoke the test again!
           rc = remoteTest.testDiamond(holder);
           if (rc == 0) {
  -            System.err.println("Passed testDiamond 2");
  +            // System.err.println("Passed testDiamond 2");
           } else {
               System.err.println("Failed testDiamond 2");
               throw new Exception("Failed testDiamond 2 with "+rc);
  @@ -140,7 +140,7 @@
           // Test for loops
           rc = remoteTest.testLoop(holder);
           if (rc == 0) {
  -            System.err.println("Passed testLoop 1");
  +            // System.err.println("Passed testLoop 1");
           } else {
               System.err.println("Failed testLoop 1");
               throw new Exception("Failed testLoop 1 with "+rc);
  @@ -149,7 +149,7 @@
           // invoke the test again!
           rc = remoteTest.testLoop(holder);
           if (rc == 0) {
  -            System.err.println("Passed testLoop 2");
  +            // System.err.println("Passed testLoop 2");
           } else {
               System.err.println("Failed testLoop 2");
               throw new Exception("Failed testLoop 2 with "+rc);
  @@ -164,7 +164,7 @@
           // Test
           rc = remoteTest.testSameArgs(holder1, holder2);
           if (rc == 0) {
  -            System.err.println("Passed testSameArgs 1");
  +            // System.err.println("Passed testSameArgs 1");
           } else {
               System.err.println("Failed testSameArgs 1");
               throw new Exception("Failed testSameArgs 1 with "+rc);
  @@ -173,7 +173,7 @@
           // invoke the test again!
           rc = remoteTest.testSameArgs(holder1,holder2);
           if (rc == 0) {
  -            System.err.println("Passed testSameArgs 2");
  +            // System.err.println("Passed testSameArgs 2");
           } else {
               System.err.println("Failed testSameArgs 2");
               throw new Exception("Failed testSameArgs 2 with "+rc);
  @@ -192,7 +192,7 @@
           // Test
           rc = remoteTest.testArgsRefSameNode(holder1, holder2);
           if (rc == 0) {
  -            System.err.println("Passed testArgsRefSameNode 1");
  +            // System.err.println("Passed testArgsRefSameNode 1");
           } else {
               System.err.println("Failed testArgsRefSameNode 1");
               throw new Exception("Failed testArgsRefSameNode 1 with "+rc);
  @@ -201,7 +201,7 @@
           // invoke the test again!
           rc = remoteTest.testArgsRefSameNode(holder1,holder2);
           if (rc == 0) {
  -            System.err.println("Passed testArgsRefSameNode 2");
  +            // System.err.println("Passed testArgsRefSameNode 2");
           } else {
               System.err.println("Failed testArgsRefSameNode 2");
               throw new Exception("Failed testArgsRefSameNode 2 with "+rc);
  @@ -218,7 +218,7 @@
           // Test
           rc = remoteTest.testArgsRefEachOther(holder1, holder2);
           if (rc == 0) {
  -            System.err.println("Passed testArgsRefEachOther 1");
  +            // System.err.println("Passed testArgsRefEachOther 1");
           } else {
               System.err.println("Failed testArgsRefEachOther 1");
               throw new Exception("Failed testArgsRefEachOther 1 with
"+rc);
  @@ -227,7 +227,7 @@
           // invoke the test again!
           rc = remoteTest.testArgsRefEachOther(holder1,holder2);
           if (rc == 0) {
  -            System.err.println("Passed testArgsRefEachOther 2");
  +            // System.err.println("Passed testArgsRefEachOther 2");
           } else {
               System.err.println("Failed testArgsRefEachOther 2");
               throw new Exception("Failed testArgsRefEachOther 2 with
"+rc);
  @@ -243,7 +243,7 @@
           // Self-Ref Test
           rc = remoteTest.testSelfRef(holder);
           if (rc == 0) {
  -            System.err.println("Passed testSelfRef 1");
  +            // System.err.println("Passed testSelfRef 1");
           } else {
               System.err.println("Failed testSelfRef 1");
               throw new Exception("Failed testSelfRef 1 with "+rc);
  @@ -252,7 +252,7 @@
           // invoke the test again!
           rc = remoteTest.testSelfRef(holder);
           if (rc == 0) {
  -            System.err.println("Passed testSelfRef 2");
  +            // System.err.println("Passed testSelfRef 2");
           } else {
               System.err.println("Failed testSelfRef 2");
               throw new Exception("Failed testSelfRef 2 with "+rc);
  
  
  

Mime
View raw message