排除Grails中Cobertura报告的插件 [英] Excluding plugins from Cobertura reports in Grails
问题描述
我在我的项目中使用了SpringSecurity插件,还使用了Cobertura插件来提供代码覆盖率报告。事情是我想SpringSecurity特定的类(登录和注销控制器,持久登录令牌等)从我的报告中排除,因为我假设他们正常工作。我希望报告只包含我的项目特定的类代码覆盖率。有什么办法可以实现这一目标?
b $ b exclusions = ['** / grails-app / conf / **','** / * any.other.package *','** / * any.class *']
xml = true
enabledByDefault = true
}
添加上面的代码并配置排除在BuildConfig.groovy中的grails-app / conf中列出
I'm using SpringSecurity plugin in my project and also Cobertura plugin for code coverage reports. The thing is I'd like the SpringSecurity specific classes (login and logout controllers, persistent login token and so on) to be excluded from my reports, since I assume they work properly. I'd like reports to contain only my project specific classes code coverage. Is there any way I can achieve that?
coverage {
exclusions = ['**/grails-app/conf/**','**/*any.other.package*','**/*any.class*']
xml = true
enabledByDefault = true
}
Add the above snippet and configure the exclusions list in BuildConfig.groovy in grails-app/conf
这篇关于排除Grails中Cobertura报告的插件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!