You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

关于org.eclipse.tycho:tycho-surefire-plugin:2.0.0:test兼容JDK11与Eclipse4.23的问询

tycho-surefire-plugin:2.0.0对JDK 11和Eclipse 4.23的支持情况及异常修复

核心结论

org.eclipse.tycho:tycho-surefire-plugin:2.0.0支持JDK 11和Eclipse 4.23(2021-09版本),你遇到的类加载异常并非版本兼容性问题,而是依赖配置缺失导致。

异常根因

从报错栈信息看,最终问题是org.eclipse.tycho.surefire.osgibooter_2.0.0无法找到org.eclipse.core.runtime.IPlatformRunnable类。这个类属于Eclipse核心运行时的org.eclipse.core.runtime bundle,Tycho Surefire插件运行时必须依赖该bundle才能正常加载测试启动类。

修复步骤

  • 检查Target Platform配置:确保你的target platform包含Eclipse 4.23完整的核心组件,特别是org.eclipse.core.runtime bundle,版本需匹配Eclipse 4.23对应的版本(一般为3.25.0系列)
  • 补充插件依赖:在测试项目的MANIFEST.MF中添加Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.25.0,4.0.0)",明确声明对核心运行时的依赖
  • 统一Tycho插件版本:确保项目中所有Tycho相关插件(如tycho-maven-plugin、tycho-surefire-plugin)的版本都是2.0.0,避免跨版本冲突

内容的提问来源于stack exchange,提问作者Birudeo Garande

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.23 14:45:37