![]() |
1
0
你需要一个
我建议在Spring集成测试中使用stub对象,在测试隔离类时使用easymock而不使用Spring。 |
![]() |
2
0
您可以在Spring上下文中使用mock: 但这并不能解决您的问题,因为它不能使Spring理解scope=“request”。您可以创建 own implementation of the request scope 但我觉得你最好不要经历这些麻烦。 简单的方法是在一个小的测试上下文中重写请求范围的bean。从技术上讲,你不是在测试最初的环境,但是你会做得更快。 |
![]() |
3
0
弹簧3.2提供了对此的支持。见“ Spring MVC Test Framework “ |
![]() |
Master Selcuk · 使用python在服务器之间创建API 3 年前 |
![]() |
Kuba Kaktus · 用python发送curl请求 3 年前 |
![]() |
Viking · 请求调度程序从表单中删除所有单词,但首先删除 7 年前 |
![]() |
Donovant · 如何在右图中编码为什么使用节点请求模块? 7 年前 |