在moven上部署spring,mybatis时,
控制台报:Caused by: java.lang.IllegalStateException: Neither GenericXmlContextLoader nor AnnotationConfigContextLoader was able to load an ApplicationContext from
解决方法:检查Test类中@RunWith下方是否写
@ContextConfiguration("classpath:ApplicationContext.xml")
出现问题为找不打xml文件;
@RunWith(SpringJUnit4ClassRunner.class)
/*@ContextConfiguration("classpath:ApplicationContext.xml")*/
public class CityProv {