ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anto...@apache.org
Subject cvs commit: ant/src/testcases/org/apache/tools/ant/taskdefs/optional/sitraka ClassFileTest.java
Date Mon, 27 Oct 2003 18:32:13 GMT
antoine     2003/10/27 10:32:13

  Modified:    src/testcases/org/apache/tools/ant/taskdefs/optional/sitraka
                        Tag: ANT_16_BRANCH ClassFileTest.java
  Log:
  Merge from HEAD
  Prevent ClassFileTest from failing under JDK 1.2
  PR: 23919
  Submitted by: Martijn Kruithof
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.7.2.1   +6 -1      ant/src/testcases/org/apache/tools/ant/taskdefs/optional/sitraka/ClassFileTest.java
  
  Index: ClassFileTest.java
  ===================================================================
  RCS file: /home/cvs/ant/src/testcases/org/apache/tools/ant/taskdefs/optional/sitraka/ClassFileTest.java,v
  retrieving revision 1.7
  retrieving revision 1.7.2.1
  diff -u -r1.7 -r1.7.2.1
  --- ClassFileTest.java	10 Feb 2003 14:14:54 -0000	1.7
  +++ ClassFileTest.java	27 Oct 2003 18:32:13 -0000	1.7.2.1
  @@ -65,6 +65,7 @@
    * Nothing special about this testcase...
    *
    * @author <a href="mailto:sbailliez@apache.org">Stephane Bailliez</a>
  + * @author <a href="mailto:martijn@kruithof.xs4all.nl">Martijn Kruithof</a>
    */
   public class ClassFileTest extends TestCase {
       public ClassFileTest(String s) {
  @@ -80,7 +81,11 @@
           assertEquals("ClassFileTest.java", clazzfile.getSourceFile());
           MethodInfo[] methods = clazzfile.getMethods();
           assertEquals(3, methods.length);
  -        assertHasMethod("void <init>()", 2, methods);
  +        if (JavaEnvUtils.isJavaVersion(JavaEnvUtils.JAVA_1_2)) {
  +            assertHasMethod("void <init>()", 1, methods);
  +        } else {
  +            assertHasMethod("void <init>()", 2, methods);
  +        }
           assertHasMethod("void testTwoLines()", 2, methods);
           assertHasMethod("void testOneLine()", 3, methods);
       }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message