简体   繁体   English

如何测试Maven / M2e插件在Eclipse中是否正确配置?

[英]how to test if maven/m2e plugin is configured correctly in eclipse?

I am trying to build a project in eclipse and then start working on it. 我正在尝试在Eclipse中构建一个项目,然后开始进行开发。 i have pulled it from my companies git hub repo and then imported into eclipse via maven. 我已经从我的公司git hub仓库中提取了它,然后通过maven导入了eclipse。

when i do mvn clean install in the command line, it all succeeds and all the tests pass. 当我在命令行中执行mvn clean install时,一切都成功了,所有测试都通过了。 in eclipse however, when i run the junit tests, some fail and i get errors. 但是在eclipse中,当我运行junit测试时,有些失败并且出现错误。 my boss says he thinks that eclipse is not configured correctly. 我的老板说他认为日食配置不正确。 how can i ensure that the eclipse is pointing at maven correctly? 我怎样才能确保日食正确指向Maven? and that everything is inline and working as it should? 一切都内联并且可以正常工作吗? i am working on eclipse kepler and really need to solve this soon. 我正在研究eclipse kepler,确实需要尽快解决。

If you just want to confirm the installation you can check that in Eclipse as below. 如果只想确认安装,则可以在Eclipse中进行如下检查。

In Eclipse Go to Windows --> Preferences --> Maven --> Installations 在Eclipse中,转到Windows->首选项-> Maven->安装

There you can find if Eclipse uses internal Maven from your suite or any external Maven is being pointed. 在这里,您可以找到Eclipse是使用套件中的内部Maven还是指向任何外部Maven。 You can as well Add or Delete any new Maven versions if you want to. 您也可以根据需要添加或删除任何新的Maven版本。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM