This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Forked Java VM exited abnormally when Ant Testing an EJB module | ||
---|---|---|---|
Product: | java | Reporter: | nabuage |
Component: | JUnit | Assignee: | Theofanis Oikonomou <theofanis> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | lucabur |
Priority: | P3 | ||
Version: | 7.2 | ||
Hardware: | PC | ||
OS: | Windows 7 | ||
See Also: | https://netbeans.org/bugzilla/show_bug.cgi?id=238865 | ||
Issue Type: | DEFECT | Exception Reporter: | |
Attachments: | Output of the failing test. Ant verbose mode set to 'verbose' |
Description
nabuage
2012-07-04 04:38:07 UTC
I had this problem with 7.2 also. At first I edited build-impl.xml, changing all the junit tasks to 'fork="false"'. While this worked, it would also reset to true whenever I changed project properties. One of the errors in the output window mentioned not finding JUnit annotations. After reading further through build-impl.xml I found some conditions looking for junit+testng. On a whim I added TestNG to Libraries>Test Compile. Problem solved. I can confirm that adding the TestNG library to the Test Libraries fixed the issue. I got the same error with NB 7.2. Adding the TestNG library doesn't work in this case because the test is part of a Spring based project where all the test suite is built around the Spring + JUnit-4.4 framework and including the TestNG introduces new errors. Please consider raising the priority to the higher value. Development activities on all our Spring based EJB projects are virtually stopped by several randomly scattered tests failing ! Providing a testcase is very complex and I will try to do this only if really needed. Pleas let me know how I can help. This is the (not very useful !) output of the test run: --- Errore: impossibile trovare o caricare la classe principale ${run.jvmargs.ide} (N.B.: this is the italian version of the error "Could not find or load main class ${run.jvmargs.ide}) Testsuite: it.mate.iside.model.JpaPuTest Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0 sec Testcase: it.mate.iside.model.JpaPuTest:null: Caused an ERROR Forked Java VM exited abnormally. Please note the time in the report does not reflect the time until the VM exit. junit.framework.AssertionFailedError: Forked Java VM exited abnormally. Please note the time in the report does not reflect the time until the VM exit. at org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:153) Test it.mate.iside.model.JpaPuTest FAILED (crashed) Created attachment 124818 [details]
Output of the failing test. Ant verbose mode set to 'verbose'
I am not sure but this bug is someway related to the bugs 216586 and 166379. The suggestion given by Johan here: http://netbeans.org/bugzilla/show_bug.cgi?id=166379#c18 works ! ( Define the property <property name="run.jvmargs.ide" value=""/> in the file build.xml ) If this is the case then it was solved by: http://hg.netbeans.org/main-silver/rev/df77a63521e7 Please try with the latest build and reopen if this is not fixed. Thank you |