1

public class MapperTest{

  /*

  *测试DepartMapper

  */

    @test

     public void testCrud(){

     //创建springioc容器

    ApplicationContext ioc = new ClassPathXmlApplicationContext("applicationContext.xml");

 // 从容器中获取mapper

 Mapper  DepartmentMapper bean = ioc.getBean(DepartmentMapper.class);

System.out.println(departmentMapper);

  

    

  

}

}

 

2