摘要:
在Test中写测试代码时,与直接启动项目不同,不会启动spring,需要手动去加载spring,具体例子如下:首先在引入spring等依赖的同时要引入junit与spring-test这两个测试工具。 ... 阅读全文
摘要:
java.lang.IllegalStateException: Failed to load ApplicationContext at org.springframework.test.context.c... 阅读全文