Eclipse Junit '-ea' 虚拟机选项

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/2522897/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-10 19:17:28  来源:igfitidea点击:

Eclipse Junit '-ea' VM Option

eclipseidejunit

提问by emeraldjava

In eclipse preferences

在日食偏好中

Windows > Preferences > Java > Junit

alt text

替代文字

What effect does the "Add '-ea' to VM args ...." checkbox option actually have on the new junit launch config?

“将'-ea'添加到VM args ....”复选框选项实际上对新的junit启动配置有什么影响?

回答by Matt McHenry

It enables the JVM to honour assertions

它使 JVM 能够遵守断言