开发者

Spring's MockHttpServlet(Request|Response) alternatives?

In 'spring-test' there's mock classes for unit testing Servlets, which is very useful. Unfortuately, I do not need any of the other Spring componenets, and do not wish to depend on spring-core in my project.

It is possible to either:

  • Use spring-test without depending on spring-core, ... (i.e se开发者_如何学Gover the mocking-classes from spring)?
  • Use an alternative mock library with similar functionality?


One option would be the project Mockrunner, which is designed for testing J2EE components such as servlets, and which includes MockHttpServletRequest and Response objects.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜