maven项目test报错Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin
来源:互联网 发布:java base64类 编辑:程序博客网 时间:2024/05/18 00:33
今天导入一个原来的maven项目,项目上右键运行JUnit Test,可以通过测试,但是运行mvn test时,报错:
Results :
Failed tests: twm.camera.core.OutPutStringTest.testPrint(): org/junit/Assert
Tests run: 2, Failures: 1, Errors: 0, Skipped: 0
[INFO] ————————————————————————
[INFO] BUILD FAILURE
[INFO] ————————————————————————
[INFO] Total time: 2.729 s
[INFO] Finished at: 2017-09-17T09:54:47+08:00
[INFO] Final Memory: 7M/19M
[INFO] ————————————————————————
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on project firstexm: There are test failures.
[ERROR]
[ERROR] Please refer to D:\workspace\mars\core\target\surefire-reports for the individual test results.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
查阅了一下很早之前的资料,发现将测试类public class OutPutStringTest改为抽像类public abstract class OutPutStringTest后,去行mvn test即可通过。
没花时间去深究这类应用问题,谨此记录一下。有知道原因的可以留言。
- maven项目test报错Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin
- maven打包报错:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin
- maven打包报错:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5:test
- maven打包报错:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5:test
- maven因为测试类打包报错Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5:test
- maven install时Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5:test
- Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.10:test (default-test)
- Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test)
- 使用maven来build报错maven Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.10:
- maven 打包【error】Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test
- Maven Build时提示:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test
- maven打包工程出现错误 Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test
- maven 打包错误解决:Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.5:test
- Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test) on
- ailed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-test)
- 解决Maven test时报错:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin
- [ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12.4:test (default-t
- Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin
- 大数据之 ZooKeeper原理及其在Hadoop和HBase中的应用
- 第一周9.14
- 1613:龟兔赛跑预测
- 使用Xshell上传和下载文件
- 每日一点C语言--开灯问题
- maven项目test报错Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin
- Android GridView自适应高度(不出现滚动条)
- js之表单校验
- 入行半年,希望在这条路走远
- 引入js、css等文件的路径问题
- java static
- Python3 面向对象编程
- 如何分叉山寨币开发底层技术并变成私链
- Apache2 Ubuntu Default Page