ServerContainer
@SpringbootTest报错 javax.websocket.server.ServerContainer not availableJ情况解决
在使用springboot单元测试出现: 11:11:10.799 [main] ERROR o.s.b.SpringApplication - [reportFailure,870] - Application run failed org.springframework.beans.factor ......
java.lang.IllegalStateException: javax.websocket.server.ServerContainer not available
spring项目能正常运行,但是单元测试报错 错误原因 注册WebSocket的Bean与spring boot内带tomcat冲突 解决办法 1.注释该类里面的代码(不推荐) 2.@springBootTest注解添加webEnvironment = SpringBootTest.WebEnvir ......
javax.websocket.server.ServerContainer not available
日志 javax.websocket.server.ServerContainer not available 源代码如下: @SpringBootTest @Runwith(SpringRunner.class) public class Test{ //…… } 单元测试类的原注解如上,运行出现 ......