方法一:使用@ImportResource
方法二:在test中
@ContextConfiguration(locations = "classpath:spring-profile.xml")
方法三:使用@PropertySource
方法四:方法四:使用SpringApplication.setSources()