会员
周边
捐助
新闻
博问
闪存
赞助商
所有博客
当前博客
我的博客
我的园子
账号设置
简洁模式
...
退出登录
注册
登录
DaisyLinux
博客园
首页
新随笔
联系
订阅
管理
2023年1月5日
Invocation of init method failed; nested exception is java.lang.IllegalStateException: javax.websocket.server.ServerContainer not available
摘要: 经查阅资料,得知SpringBootTest在启动的时候不会启动服务器,所以WebSocket自然会报错,这个时候需要添加选项webEnvironment,以便提供一个测试的web环境。如下: @RunWith(SpringRunner.class)@SpringBootTest(webEnviro
阅读全文
posted @ 2023-01-05 16:55 DaisyLinux
阅读(257)
评论(0)
推荐(0)
编辑
公告