I
have started to use jWebUnit for testing a large an web application. The
issue I had was that after about 100
tests or so it runs out of memory. Increase the heap just delays the error. I
have currently 600 tests but it could end up being over 3000. I would like to be
able to run all of them say as a over night process. I have just tried
re-working the TestCase so that the Jetty web server is stopped and start
between a group of tests (number is determined by me) as I was thinking that it
might be the Open sessions from the login steps. Even if I restart the web
server in a fine grained level it will still run out of memory. I have run out
of ideas.
The lists and web searches does not inidicate
anyone else facing this issue so I'm not sure people are using the tests
extensively. I call the only cleanup like method I can find in the http
API. I have added my own test runner that
will at determined points restart the web server (Jetty) so that open sessions
will get cleared. I null out the web conversation after the test to assist with
garbage collection (which did help a fair bit). All of these changes have helped
so its better than it was but I still cannot run all of the tests in one single
execution (using Eclipse).
So has anyone found these issues?
How are you going about it? It might be the application leaking or
eclipse, so how could I determine whats is going on in this
case. It would
be great if you could provide some idea(s) or advice please.
Thanks in
advance.
Cheers
David.
