Running test case in Eclipse? [message #13442] |
Wed, 23 July 2008 21:56  |
Eclipse User |
|
|
|
Originally posted by: barbariansouth.ymail.com
Hello all,
I've been using Maven for some time and new to the m2e plugin..... After
I installing the plugin and make my project maven enabled, I notice that
when I code some test case and want to run directly in eclipse, the
binaries of the test case seems not re-compiled and the test is executed
using the old version.... I need to manually run the "mvn install" or
something like that before my test case is refreshed during the test case
execution....
Is there any way to make my test case run with the latest binaries?
Thanks in advance...
|
|
|
Re: Running test case in Eclipse? [message #13462 is a reply to message #13442] |
Wed, 23 July 2008 22:47   |
Eclipse User |
|
|
|
Originally posted by: igor.ifedorenko.com
Barbarian,
Assuming you're using junit, you should be able to right-click on the
project or individual test, Run As->JUnit Test. This will construct
proper Maven test classpath (see [1] if you're interested in details)
but use Eclipse JUnit UI to show test execution progress and results.
Generally, m2e does not automatically package/installs the projects,
but, uses project output folders instead. We call it "workspace artifact
resolution". It is enabled by default for all actions performed by m2e
directly (compile classpath resolution, project import, run as junit
test, etc) but needs to be explicitly enabled for Run As Maven ...
actions (see [2]).
[1] http://docs.codehaus.org/display/M2ECLIPSE/Runtime+classpath
[2]
http://docs.codehaus.org/display/M2ECLIPSE/Developing+and+de bugging+Maven+plugins
Barbarian South wrote:
> Hello all,
>
> I've been using Maven for some time and new to the m2e plugin.....
> After I installing the plugin and make my project maven enabled, I
> notice that when I code some test case and want to run directly in
> eclipse, the binaries of the test case seems not re-compiled and the
> test is executed using the old version.... I need to manually run the
> "mvn install" or something like that before my test case is refreshed
> during the test case execution....
>
> Is there any way to make my test case run with the latest binaries?
> Thanks in advance...
>
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04557 seconds