问题遇到的现象和发生背景
为什么高版本的spring-context不能用junit,在低版本中可以正常使用
遇到的现象和发生背景,请写出第一个错误信息
org.junit.platform.commons.JUnitException: TestEngine with ID 'junit-jupiter' failed to discover tests
Caused by: org.junit.platform.commons.JUnitException: ClassSelector [className = 'spring.TestIOC'] resolution failed
Caused by: java.lang.UnsupportedClassVersionError: org/springframework/context/ApplicationContext has been compiled by a more recent version of the Java Runtime (class file version 61.0), this version of the Java Runtime only recognizes class file versions up to 55.0 ![img](https://img-mid.csdnimg.cn/release/static/image/mid/ask/331951318276123.png "#left")
<!-- https://mvnrepository.com/artifact/org.springframework/spring-context -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
<version>5.3.1</version>
</dependency>
在5.几的版本下就可以,而6.几的版本都不行