commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dennis Lundberg <denn...@apache.org>
Subject [logging] Running tests on earlier JVMs
Date Wed, 04 Jul 2007 21:10:44 GMT
Hi

I'm trying to put together an an script that will do nothing more than 
run the tests for commons logging. It's going fairly well. A couple of 
issues that I found though that I need assistance with.

Failing test
============

The two test files in the security package both fail. These tests were 
run using a 1.3 jvm (see below why that is).


Testsuite: org.apache.commons.logging.security.SecurityAllowedTestCase
Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0,016 sec
------------- Standard Output ---------------


testing permission:class 
java.util.PropertyPermission:(java.util.PropertyPermission 
sun.net.inetaddr.ttl read)
------------- ---------------- ---------------

Testcase: testAllAllowed took 0,016 sec
	Caused an ERROR
null
java.lang.NoClassDefFoundError
	at java.lang.System.setSecurityManager0(System.java:239)
	at java.lang.System.setSecurityManager(System.java:208)
	at 
org.apache.commons.logging.security.SecurityAllowedTestCase.tearDown(SecurityAllowedTestCase.java:77)
	at 
org.apache.commons.logging.PathableTestSuite.runTest(PathableTestSuite.java:142)



Testsuite: org.apache.commons.logging.security.SecurityForbiddenTestCase
Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0,015 sec

Testcase: testAllForbidden took 0,015 sec
	Caused an ERROR
null
java.lang.NoClassDefFoundError
	at java.lang.System.setSecurityManager0(System.java:239)
	at java.lang.System.setSecurityManager(System.java:208)
	at 
org.apache.commons.logging.security.SecurityForbiddenTestCase.tearDown(SecurityForbiddenTestCase.java:80)
	at 
org.apache.commons.logging.PathableTestSuite.runTest(PathableTestSuite.java:142)



Finding a (really old) platform to run on
=========================================

We've said earlier that we should ideally run the tests using a 1.2 jvm. 
So I installed 1.2.2_17 on my Windows machine and started running tests. 
That didn't go to well. Here's what I get:


Buildfile: build-testing.xml
A nonfatal internal JIT (3.10.107(x)) error 'chgTarg: Conditional' has 
occurred in :
   'org/apache/tools/ant/Project.addReference 
(Ljava/lang/String;Ljava/lang/Object;)V': Interpreting method.
   Please report this error in detail to 
http://java.sun.com/cgi-bin/bugreport.cgi

A nonfatal internal JIT (3.10.107(x)) error 'chgTarg: Conditional' has 
occurred in :
   'org/apache/tools/ant/Project.fireMessageLoggedEvent 
(Lorg/apache/tools/ant/BuildEvent;Ljava/lang/String;I)V': Interpreting 
method
.
   Please report this error in detail to 
http://java.sun.com/cgi-bin/bugreport.cgi

A nonfatal internal JIT (3.10.107(x)) error 'chgTarg: Conditional' has 
occurred in :
   'org/apache/tools/ant/ComponentHelper.addCreatedTask 
(Ljava/lang/String;Lorg/apache/tools/ant/Task;)V': Interpreting method.
   Please report this error in detail to 
http://java.sun.com/cgi-bin/bugreport.cgi


init:
      [echo] -------- Logging Wrapper Library 1.1.1-SNAPSHOT --------

discovery:

log4j12-test-warning:

test:
      [echo] Test output can be found in directory 
G:\apache\jakarta\commons-logging/target/test-reports.
    [delete] Deleting directory 
G:\apache\jakarta\commons-logging\target\test-reports
     [mkdir] Created dir: 
G:\apache\jakarta\commons-logging\target\test-reports
      [echo] executing tests [**/*TestCase.java]
A nonfatal internal JIT (3.10.107(x)) error 'chgTarg: Conditional' has 
occurred in :
   'org/apache/tools/ant/ComponentHelper.getDataTypeDefinitions 
()Ljava/util/Hashtable;': Interpreting method.
   Please report this error in detail to 
http://java.sun.com/cgi-bin/bugreport.cgi

A nonfatal internal JIT (3.10.107(x)) error 'chgTarg: Conditional' has 
occurred in :
   'org/apache/tools/ant/DirectoryScanner.scan ()V': Interpreting method.
   Please report this error in detail to 
http://java.sun.com/cgi-bin/bugreport.cgi

A nonfatal internal JIT (3.10.107(x)) error 'chgTarg: Conditional' has 
occurred in :
   'org/apache/tools/ant/util/FileUtils.createTempFile 
(Ljava/lang/String;Ljava/lang/String;Ljava/io/File;)Ljava/io/File;': 
Interpret
ing method.
   Please report this error in detail to 
http://java.sun.com/cgi-bin/bugreport.cgi

A nonfatal internal JIT (3.10.107(x)) error 'chgTarg: Conditional' has 
occurred in :
   'org/apache/tools/ant/taskdefs/ProcessDestroyer.add 
(Ljava/lang/Process;)Z': Interpreting method.
   Please report this error in detail to 
http://java.sun.com/cgi-bin/bugreport.cgi

     [junit] java.lang.IllegalMonitorStateException: current thread not 
owner
     [junit]     at 
org.apache.tools.ant.taskdefs.StreamPumper.run(StreamPumper.java, 
Compiled Code)
     [junit]     at java.lang.Thread.run(Thread.java:479)
     [junit] java.lang.IllegalMonitorStateException: current thread not 
owner
     [junit]     at 
org.apache.tools.ant.taskdefs.StreamPumper.run(StreamPumper.java, 
Compiled Code)
     [junit]     at java.lang.Thread.run(Thread.java:479)


And then it just hangs! This is done using ant 1.6.5. When I tried with 
ant 1.5.4 it didn't work at all because we use "propertyset":

BUILD FAILED
file:G:/apache/jakarta/commons-logging/build-testing.xml:171: Unexpected 
element "propertyset"

I don't know the jvm requirements for the different ant versions.


I'll be checking in the ant script shortly... Any pointers to what might 
be going wrong here is greatly appreciated.

-- 
Dennis Lundberg

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


Mime
View raw message