冲突的模块版本。模块[groovy-xml在版本4.xx中加载,您正在尝试加载版本3.xx
我正在努力为Springboot Rest API设置WireMock,并使用Spring Cloud的REST保证和Spring-Cloud-Starter-starter-Contract-Contract-stub-runner。当我运行样本集成测试时,我会遇到模块冲突错误
I am working to setup wiremock for springboot rest api and using rest assured and spring-cloud-starter-contract-stub-runner from spring cloud. when i run the sample integration test i encounter module conflict error
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(8)
在Rest Assuble的GitHub页面上找到了这种解决方法。您可以用此
susped recust的github页面
Found this workaround on Rest Assured's GitHub page. You replace Rest Assured's dependency with this one
Rest Assured's Github Page
。您的班级路径只会从Spring-Cloud-Starter-Contract-stub-Runner依赖性中有1个凹槽
. your class path will only have 1 groovy from spring-cloud-starter-contract-stub-runner dependency
groovy.lang.groovyruntimeException:冲突的模块版本。模块[Groovy-XML已加载4.0.6版,您正在尝试加载版本3.0.19
groovy.lang.GroovyRuntimeException: Conflicting module versions. Module [groovy-xml is loaded in version 4.0.6 and you are trying to load version 3.0.19
1只是手动从pom文件中删除了静止的依赖关系。
2添加到POM文件
3 Maven Clean
4 Maven Compile
5 Maven -Reload(刷新)
1 just manually remove rest-assured dependency from POM file.
2 add to the pom file
3 Maven clean
4 Maven Compile
5 Maven - Reload(refresh)
Gradle依赖性:
Gradle dependencies:
删除与Groovy相关的依赖项并尝试运行您的项目,希望它可以解决问题。确保您使用的是最新版本的REST-ASURE IE 5.1.1或更高版本
Remove the groovy related dependencies and try to run your project, hopefully it will solve the problem. Make sure that you are using the latest version of rest-assure i.e 5.1.1 or later on
休息的版本5.3.0
Rest Assured version 5.3.0