GWT (Maven plugin): how to enable assert checking for server side code?

一曲冷凌霜 提交于 2020-01-07 05:36:13

问题


Basically I put a lot of 'assert's allover the service code (server side). I just realized that those were ignored as the execution went through upon hitting 'false' resulting expressions. However, to my surprise, assertions on the client side got checked.

I tried the following to no success.

mvn gwt:debug -Dgwt.extraJvmArgs="-Xmx1536m -Xms1536m -XX:MaxPermSize=512m -ea"

Any clue?


回答1:


Maven does not pass VM arguments to java executables started from maven (e.g. unit tests). You have to specify those variables in maven pom.

The surefire plugin supports an additional setting attribute called "argLine" for that, just as an example.



来源:https://stackoverflow.com/questions/7789635/gwt-maven-plugin-how-to-enable-assert-checking-for-server-side-code

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!