I just developed with pleasure :-)

It doesn't matter how long you use idea, you always discover something
new you can do which makes you say... Dang this thing is good...

Today's coolness, at least to me and others here who have not done this
before:

we have unit tests which require Tomcat to be running so we can test and
parse html returned from our app to get as much UI test into the app as
possible. Normally we start Tomcat separately and just hit the box.
Today one of the tests was failing, and I wanted to know where. I
decided to try firing up Tomcat in idea in Debug mode, and run my tests
in idea and step through the various calls of the tests to see what was
going on. Worked like a charm.

Not sure why we never thought of this before, lack of documentation,
tunnel vision, lack of good morning donuts... what ever it is, this is
very cool that idea can handle that, and allow us to stay completely in
the ide while doing our work.

It's things like this that make me try harder to keep finding stuff to
make IDEA better.

Hats off folks.

R

4 comments

Robert

>we have unit tests which require Tomcat to be running ..
>.. decided to try firing up Tomcat in idea in Debug mode, and run my tests
>in idea and step through
>

Have you tried/considered Jetty? You can start it up and load it in a
few java lines.
Last time I tried - a year ago - it was way faster to launch than
Tomcat, so you could restart it for each isolated test suite.

Alain.

0

In article <cqag6o$e7s$1@is.intellij.net>,
Alain Ravet <alain.ravet@biz.tiscali.be> wrote:

Robert

>we have unit tests which require Tomcat to be running ..
>.. decided to try firing up Tomcat in idea in Debug mode, and run my tests
>in idea and step through
>

Have you tried/considered Jetty? You can start it up and load it in a
few java lines.
Last time I tried - a year ago - it was way faster to launch than
Tomcat, so you could restart it for each isolated test suite.


Interesting. I don't need to restart for every test suite, I just need
tomcat to run and just accept connections to verify UI and other things
which have to be tested in a container. Also the Tomcat startup is
minimal (7 seconds) and doesn't require any extra code or libs to run
tests. If my app was not starting Tomcat startup on my box in idea is 4
seconds... not sure how much faster Jetty will be ;)

R

0

Alain Ravet wrote:

Robert

>> we have unit tests which require Tomcat to be running ..
>> .. decided to try firing up Tomcat in idea in Debug mode, and run my
>> tests in idea and step through
>>


Have you tried/considered Jetty? You can start it up and load it in a
few java lines.
Last time I tried - a year ago - it was way faster to launch than
Tomcat, so you could restart it for each isolated test suite.

Alain.

We use Jetty too (for our application, not just testing).

0

Yes, Jetty looks a little faster than Tomcat (I have some experience
designing web app for both Tomcat and Jetty). But I would like to aware you
about possible issues that you can met using Jetty for testing and Tomcat
for deployment - they implement differently some general interfaces like
HttpSession (afair we met situation when the same jsp-page results were
different for Jetty and Tomcat, it was something about
operation/initialization of attributes but I do not remember exactly session
or request ones).

Take care,
Andrei



"Amnon I. Govrin" <amnon@netvision.net.il> wrote in message
news:cqbh7m$gj5$1@is.intellij.net...

Alain Ravet wrote:

>> Robert
>>
>>> we have unit tests which require Tomcat to be running ..
>>> .. decided to try firing up Tomcat in idea in Debug mode, and run my
>>> tests in idea and step through
>>>
>>
>> Have you tried/considered Jetty? You can start it up and load it in a few
>> java lines.
>> Last time I tried - a year ago - it was way faster to launch than Tomcat,
>> so you could restart it for each isolated test suite.
>>
>> Alain.

We use Jetty too (for our application, not just testing).



0

Please sign in to leave a comment.