[Building Sakai] Debugging unit tests in Eclispe

Bryan Holladay holladay at longsight.com
Tue Jul 16 13:40:03 PDT 2013


I simply just right click in Eclipse the test I want to debug and choose
"debug as...-> JUnit Test".  I'm not using maven or running tomcat through
eclipse.  Tomcat doesn't even have to be started or maven compiling.


On Tue, Jul 16, 2013 at 4:32 PM, Brian Jones <bjones86 at uwo.ca> wrote:

> Hey Bryan,
>
> My 'Debug as...' menu was empty. So I created a new Maven Build
> configuration with the goal of '-Dmaven.surefire.debug test'. But when I
> use
> this, it just waits for a socket attach on port 5005.
>
> When I attach my remote debugger to 5005, it just runs from start to finish
> without stopping on the breakpoints. Not sure if I'm missing something
> here,
> are there any instructions on this?
>
> Brian Jones
> Applications Development
> Information Technology Services
> Support Services Building, Room 4326
> Western University
> (519) 661-2111 x86969
> bjones86 at uwo.ca
>
> From: Bryan Holladay [mailto:holladay at longsight.com]
> Sent: Tuesday, July 16, 2013 4:20 PM
> To: Brian Jones
> Cc: sakai-dev
> Subject: Re: [Building Sakai] Debugging unit tests in Eclispe
>
> I've never tried it through socket attaches.  Using the normal Eclipse
> "Debug as..." button always worked for me.  I'm assuming this isn't an
> option and you have to connect to an external socket?
>
> On Tue, Jul 16, 2013 at 4:09 PM, Brian Jones <bjones86 at uwo.ca> wrote:
> Hello,
>
> Does anyone have any positive experience with debugging unit tests in
> Eclipse? I can get mvn in debug mode to listen for a socket attach, and I
> can attach my Eclipse debugger to it just fine, but it never respects the
> breakpoints I've set. Once it's attached, it just does the tests from start
> to finish without pausing on my breakpoitns.
>
> I've tried the following mvn commands:
>
>         - mvnDebug -DforkCount=0 test
>         - mvnDebug -DforkMode=never test
>
> Cheers,
>
> Brian Jones
> Applications Development
> Information Technology Services
> Support Services Building, Room 4326
> Western University
> (519) 661-2111 x86969
> bjones86 at uwo.ca
>
>
>
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>
> TO UNSUBSCRIBE: send email to
> sakai-dev-unsubscribe at collab.sakaiproject.org
> with a subject of "unsubscribe"
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20130716/144cb178/attachment.html 


More information about the sakai-dev mailing list