1、下载spring5的jar包。https://github.com/spring-projects/spring-framework
2、创建空的java 项目,引入刚下载的源码包。最少4个。
并创建一下小毛驴。
编写测试类。引入 org.junit.Test
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
<bean id="customerBean" class="User"></bean>
</beans>
到此结束。我这里用3分钟,你呢?