OutOfMemory error in JUnit
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   jalo_javier
Posted On:   Friday, February 15, 2008 09:47 PM

Hello



I'm using JUnit 4 to make some test to my code but, when i try to run some code in oneTimeSetUp() or setUp() method i obtain the following error:



java.lang.OutOfMemoryError: Java heap space



The question is that the code that give this error, in my main app runs ok.. so.. what's the problem?


Thanks!

Re: OutOfMemory error in JUnit

Posted By:   Robert_Lybarger  
Posted On:   Saturday, February 16, 2008 12:45 AM

problem is that junit and your unit test fixtures (or whatever) added some extra overhead and pushed you over the heap limit you're running with. Look into "-Xmx" argument to bump the max heap size. (Google around for that.)
About | Sitemap | Contact