Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 508334 - dev-java/commons-io-2.4 fails org.apache.commons.io.CharsetsTestCase
Summary: dev-java/commons-io-2.4 fails org.apache.commons.io.CharsetsTestCase
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Java (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Java team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-04-21 16:48 UTC by Achim Derigs
Modified: 2015-11-15 20:36 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
/var/tmp/portage/dev-java/commons-io-2.4/temp/build.log (build.log,4.98 KB, text/plain)
2015-11-15 18:52 UTC, Achim Derigs
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Achim Derigs 2014-04-21 16:48:17 UTC
# emerge -av commons-io

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R    ] dev-java/commons-io-2.4:1  USE="{test*} -doc -source" 0 kB

Total: 1 package (1 reinstall), Size of downloads: 0 kB

Would you like to merge these packages? [Yes/No] 

>>> Verifying ebuild manifests

>>> Emerging (1 of 1) dev-java/commons-io-2.4
 * commons-io-2.4-src.tar.gz SHA256 SHA512 WHIRLPOOL size ;-) ...                                                                                [ ok ]
 * Using: oracle-jdk-bin-1.7
>>> Unpacking source...
>>> Unpacking commons-io-2.4-src.tar.gz to /var/tmp/portage/dev-java/commons-io-2.4/work
>>> Source unpacked in /var/tmp/portage/dev-java/commons-io-2.4/work
>>> Preparing source in /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src ...
Rewriting build.xml
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src ...
Rewriting attributes
Rewriting ./build.xml
>>> Source configured.
>>> Compiling source in /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src ...
 * Disabling all optional ANT_TASKS
Buildfile: /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/build.xml

init:
     [echo] -------- Commons IO 2.4 --------
    [mkdir] Created dir: /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target
    [mkdir] Created dir: /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/classes
    [mkdir] Created dir: /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/test-classes

compile:
    [javac] Compiling 103 source files to /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/classes

jar:
    [mkdir] Created dir: /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/classes/META-INF
     [copy] Copying 1 file to /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/classes/META-INF
     [copy] Copying 1 file to /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/classes/META-INF
      [jar] Building jar: /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/commons-io-2.4.jar

BUILD SUCCESSFUL
Total time: 2 seconds
>>> Source compiled.
 * Using following ANT_TASKS: ant-junit
Buildfile: /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/build.xml

init:
     [echo] -------- Commons IO 2.2-SNAPSHOT --------

compile:

check-availability:
     [echo] doing check-availability...

download-dependencies:

compile.tests:
    [javac] Compiling 95 source files to /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/test-classes
    [javac] Note: Some input files use or override a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.
    [javac] Note: /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/src/test/java/org/apache/commons/io/comparator/CompositeFileComparatorTest.java uses unchecked or unsafe operations.
    [javac] Note: Recompile with -Xlint:unchecked for details.

test:
    [mkdir] Created dir: /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/ant-reports
    [junit] Running org.apache.commons.io.ByteOrderMarkTestCase
    [junit] Tests run: 9, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.027 sec
    [junit] Running org.apache.commons.io.CharsetsTestCase
    [junit] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.013 sec

BUILD FAILED
/var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/build.xml:153: Test org.apache.commons.io.CharsetsTestCase failed

Total time: 4 seconds
 * ERROR: dev-java/commons-io-2.4 failed (test phase):
 *   eant failed
 * 
 * Call stack:
 *     ebuild.sh, line   93:  Called src_test
 *   environment, line 3857:  Called eant 'test' '-Dgentoo.classpath=/usr/share/junit-4/lib/junit.jar:/var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/src/test/resources' '-Dlibdir=libdir' '-Djava.io.tmpdir=/var/tmp/portage/dev-java/commons-io-2.4/temp'
 *   environment, line  548:  Called die
 * The specific snippet of code:
 *       ant ${antflags} "${@}" || die "eant failed"
 * 
 * If you need support, post the output of `emerge --info '=dev-java/commons-io-2.4'`,
 * the complete build log and the output of `emerge -pqv '=dev-java/commons-io-2.4'`.
!!! When you file a bug report, please include the following information:
GENTOO_VM=oracle-jdk-bin-1.7  CLASSPATH="" JAVA_HOME="/opt/oracle-jdk-bin-1.7.0.51"
JAVACFLAGS="-source 1.6 -target 1.6" COMPILER="javac"
and of course, the output of emerge --info =commons-io-2.4
 * The complete build log is located at '/var/tmp/portage/dev-java/commons-io-2.4/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/dev-java/commons-io-2.4/temp/environment'.
 * Working directory: '/var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src'
 * S: '/var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src'

>>> Failed to emerge dev-java/commons-io-2.4, Log file:

>>>  '/var/tmp/portage/dev-java/commons-io-2.4/temp/build.log'

 * Messages for package dev-java/commons-io-2.4:

 * ERROR: dev-java/commons-io-2.4 failed (test phase):
 *   eant failed
 * 
 * Call stack:
 *     ebuild.sh, line   93:  Called src_test
 *   environment, line 3857:  Called eant 'test' '-Dgentoo.classpath=/usr/share/junit-4/lib/junit.jar:/var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/src/test/resources' '-Dlibdir=libdir' '-Djava.io.tmpdir=/var/tmp/portage/dev-java/commons-io-2.4/temp'
 *   environment, line  548:  Called die
 * The specific snippet of code:
 *       ant ${antflags} "${@}" || die "eant failed"
 * 
 * If you need support, post the output of `emerge --info '=dev-java/commons-io-2.4'`,
 * the complete build log and the output of `emerge -pqv '=dev-java/commons-io-2.4'`.
 * The complete build log is located at '/var/tmp/portage/dev-java/commons-io-2.4/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/dev-java/commons-io-2.4/temp/environment'.
 * Working directory: '/var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src'
 * S: '/var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src'
# cat /var/tmp/portage/dev-java/commons-io-2.4/work/commons-io-2.4-src/target/ant-reports/TEST-org.apache.commons.io.CharsetsTestCase.txt Testsuite: org.apache.commons.io.CharsetsTestCase
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.013 sec

Testcase: initializationError took 0.002 sec
        Caused an ERROR
org/hamcrest/SelfDescribing
java.lang.NoClassDefFoundError: org/hamcrest/SelfDescribing
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(ClassLoader.java:800)
        at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
        at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
        at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
Caused by: java.lang.ClassNotFoundException: org.hamcrest.SelfDescribing
        at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
Comment 1 Patrice Clement gentoo-dev 2015-10-16 14:58:10 UTC
>>> Install commons-io-2.4 into /var/tmp/portage/dev-java/commons-io-2.4/image/ category dev-java
>>> Completed installing commons-io-2.4 into /var/tmp/portage/dev-java/commons-io-2.4/image/

I can't reproduce this issue. Can you try again and attach a build.log this time around if it occurs?
Comment 2 Achim Derigs 2015-11-15 18:52:49 UTC
Created attachment 417036 [details]
/var/tmp/portage/dev-java/commons-io-2.4/temp/build.log

Tried again ...
Comment 3 Patrice Clement gentoo-dev 2015-11-15 20:36:00 UTC
I'm not experiencing any failure but have added JAVA_ANT_ENCODING="ISO-8859-1" to the ebuild. Can you try again? If it keeps failing, disable the tests for this package since compiling goes through.