Skip to content

fix: make reset rollback test cross-platform - #7

Merged
z2z23n0 merged 1 commit into
mainfrom
fix/reset-reactivation-test
Jul 22, 2026
Merged

fix: make reset rollback test cross-platform#7
z2z23n0 merged 1 commit into
mainfrom
fix/reset-reactivation-test

Conversation

@z2z23n0

@z2z23n0 z2z23n0 commented Jul 22, 2026

Copy link
Copy Markdown
Owner

Mainline Intent

Intent: int_1b88eca5
Status: proposed
Title: 修复 reset 回滚测试的跨平台故障注入

What changed

将 reset 回滚测试从按 runner 调用次数注入失败,改为在 launchctl bootstrap 或 systemctl enable 注册命令上一次性注入失败,并补充两类命令的识别测试。

Why

watchdog 合入后 macOS 与 Linux 的停用调用次数不同,固定偏移只能在 launchd 路径命中,导致 Ubuntu/Go 1.22 将未触发故障误判为 reset 意外成功。

Decisions

  • 如何稳定触发 scheduler 重新激活失败: 按注册命令语义匹配并只失败一次 (该方式同时覆盖 launchd bootstrap 和 systemd enable,不依赖平台内部调用数量,并允许回滚阶段的第二次激活成功。)
    • Rejected: 继续维护每个平台的调用次数偏移

Subsystems: cli

@z2z23n0
z2z23n0 marked this pull request as ready for review July 22, 2026 12:01
@z2z23n0
z2z23n0 merged commit 387f070 into main Jul 22, 2026
2 checks passed
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