相关疑难解决方法(0)

在junit测试类中重用spring应用程序上下文

我们有一堆JUnit测试用例(集成测试),它们在逻辑上分为不同的测试类.

我们能够为每个测试类加载一次Spring应用程序上下文,并将其重用于JUnit测试类中的所有测试用例,如http://static.springsource.org/spring/docs/current/spring-framework-reference中所述./html/testing.html

但是,我们只是想知道是否有一种方法只为一堆JUnit测试类加载一次Spring应用程序上下文.

FWIW,我们使用Spring 3.0.5,JUnit 4.5并使用Maven来构建项目.

junit spring spring-test junit4

73
推荐指数
4
解决办法
6万
查看次数

标签 统计

junit ×1

junit4 ×1

spring ×1

spring-test ×1