m2eclipse is always uses information from pom.xml You can verify that your Maven configuration is correct by launching Maven "package" either from Eclipse or using command line Maven, and you should see that your tests are compiled and executed there.

Once you get Maven working, you can bring your Eclipse project up to date with pom.xml using Maven / Update Project configuration and after that launching Maven tests using "Run as... / JUnit test" should also work.

If that doesn't resolve it for your project, please open new JIRA issue and attach test project that would allow us to reproduce it.

 Thanks

 Eugene


youhaodeyi wrote:
There is one problem when using Maven project configuration. It puts test
classes and java classes into separate directories. If I run the test code
which import classes from java classes, it will prompt cannot find class.


Eugene Kuleshov wrote:
We don't expect you to configure any folders. You should be using "Maven / Update project configuration" action from the project popup menu to bring Eclipse project configuration up to date with pom.xml

  regards,
  Eugene


youhaodeyi wrote:
I didn't use Maven project setting. I setup the output folder to classes.
Is this the problem?


Eugene Kuleshov wrote:
  It is in project project popup menu. Properties / Maven.
  http://docs.codehaus.org/display/M2ECLIPSE/Dependency+Management

  regards,
  Eugene


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email


Reply via email to