Skip to content

test(maven): Spring Boot 调试端到端测试,文档标明调试可用 - #29

Merged
1lck merged 1 commit into
mainfrom
test/spring-boot-debug-e2e
Nov 17, 2026
Merged

1lck merged 1 commit into
mainfrom
test/spring-boot-debug-e2e

Conversation

@1lck

@1lck 1lck commented Nov 17, 2026

Copy link
Copy Markdown
Contributor

关联 Issue / Linked issue

Refs 1lck/Lithe-IDEA#2107(Spring Boot 运行配置可直接点调试)。宿主配套 1lck/Lithe-IDEA#2113(已合入 1ce4085e7):服务运行按 debug.configurationType 选出其他插件的调试适配器,分配端口、请求本插件准备挂起的服务后连接;同时修好真实端到端测试暴露的 3 个宿主缺陷。

PR 类型 / Type

改动说明 / What changes

  • 新增 e2e/host/desktop/internal/workbench/official_maven_plugin_debug_e2e_test.go,测试 TestOfficialMavenPluginDebugsASpringBootApplication:
    • 和 Java Support 发布包一起安装,打开两模块 Spring Boot 项目,确认 ShopApplication 可调试;
    • 在 ShopApplication.java 设断点,从标题栏点调试;
    • 等 java 适配器连上;
    • GET /hello 停在断点,栈顶是断点所在行,且请求在断点处阻塞;
    • 继续后返回 Hello, Lithe from eu-west;
    • 在调试窗口停止后,服务和会话都结束、端口释放,关闭项目后插件安装目录不变。
  • official_maven_plugin_e2e_test.go 的 installOfficialPluginArchive:照 app.go 给自己打开的插件服务接上 LogDirectory。Java Support 的语言服务器启动参数用到 ${logDir},没有日志目录时 Core 拒绝启动(The launch request has no usable logDirectory.)。测试里用 pluginFilesLog 提供目录。
  • e2e/host/lithe-host.json:
    • 宿主固定到 1ce4085e7(合入 #2113 的 main);
    • workbench 用例加入 DebugsASpringBootApplication;
    • LITHE_TEST_JAVA_PLUGIN_ARCHIVE 的说明补上“它的 java 适配器负责调试”。
  • README.md、docs/feature-matrix.md:去掉“调试待宿主支持”;maven-run-applications 写明调试可用,并记录这次的验证结果,以及宿主修好的 3 个问题。

验证 / Verification

命令或操作 平台 结果
把 3 个 official_maven_plugin_*_test.go 复制进宿主 #2113 分支,用 LITHE_TEST_MAVEN_PLUGIN_ARCHIVE=dist/maven-build-1.0.0-darwin.zip、LITHE_TEST_JAVA_PLUGIN_ARCHIVE=Lithe-Java-Support-4.0.1-darwin-arm64.zip 运行 scripts/desktop/desktop-go.sh test ./internal/workbench/ -run '^TestOfficialMavenPlugin' -count=1 macOS arm64 DebugsASpringBootApplication PASS(17.4s)、BuildsAReactor PASS(48.9s)、RunsASpringBootApplication PASS(6.9s)
同一测试在宿主修复前 macOS arm64 依次失败:没有日志目录(本 PR 修的测试搭建问题)→ lsp.request: The language server did not advertise this capability. (not_supported)(#2113 修的宿主问题)

未能执行的检查: 没有用 node scripts/e2e-host.mjs 从固定修订重新检出宿主并编译 Core 再跑一遍。上面的测试是在 #2113 分支上跑的,它和固定修订只差 main 上两个与运行和调试无关的提交(#2110、#2111)。Windows 没有运行。

🤖 Generated with Claude Code

- 新增宿主端到端测试 TestOfficialMavenPluginDebugsASpringBootApplication:和 Java Support
  一起安装,断点命中、继续后请求完成、停止后服务结束;登记进 lithe-host.json,宿主固定到
  合入 1lck/Lithe-IDEA#2113 的 1ce4085e7。
- installOfficialPluginArchive 像 app.go 一样给插件服务接上 LogDirectory,语言服务器的
  ${logDir} 才有值。
- README 和功能矩阵:调试已可用,记录验证结果。

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@1lck
1lck merged commit 1f32604 into main Nov 17, 2026
7 checks passed
@1lck
1lck deleted the test/spring-boot-debug-e2e branch November 17, 2026 14:50
@1lck 1lck mentioned this pull request Nov 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant