Skip to content

emrg: 启用 Windows CI 纯逻辑 TUI 测试(移除 65 个过时 skipif) - #406

Merged
argszero merged 1 commit into
masterfrom
feature/win-ci-pure-logic-tests
Aug 5, 2026
Merged

emrg: 启用 Windows CI 纯逻辑 TUI 测试(移除 65 个过时 skipif)#406
argszero merged 1 commit into
masterfrom
feature/win-ci-pure-logic-tests

Conversation

@argszero

@argszero argszero commented Aug 5, 2026

Copy link
Copy Markdown
Owner

背景

#401 (R123) 后 Windows 已有原生 TUI(Win32Console raw mode + stdin/resize 线程化),terminal.py 的 termios/fcntl/tty import 有 None 保护,python_tui 包在 Windows 可安全 import。

问题

6 个测试文件仍带 'TUI is POSIX-only (fcntl/termios)'过时 skipif——Windows 构建(build-release.yml regression gate 在 windows-2025 跑 pytest)跳过 65 个纯逻辑测试:buffer 写入 / ANSI 生成 / 输入解析逻辑在 Windows 上完全无回归保障

改动

  1. test_buffer / test_output / test_input_parser(65 测试):移除 skipif——纯逻辑、无平台调用、import 链安全 → Windows CI 将实际执行
  2. test_app_widgets / test_daemon_manager / test_daemon_manager_e2e:保留 skip(交互/daemon 生命周期依赖 POSIX 终端/进程语义),注释更新为准确原因(不再声称 POSIX-only)

验证

  • macOS 全量回归:470 passed
  • from emrg.client.app import run_client OK + emrg --help OK
  • Windows 侧由本 PR 触发 build-release 前的 test.yml(仅 ubuntu)验证语法;windows-2025 上 pytest 将在下次 tag 构建时执行

#401 (R123) 后 Windows 已有原生 TUI(Win32Console raw mode + stdin/resize 线程化),
terminal.py 的 termios/fcntl/tty import 有 None 保护,python_tui 包在 Windows 可安全 import。

历史遗留问题:6 个测试文件仍带 'TUI is POSIX-only (fcntl/termios)' 的过时 skipif,
导致 Windows 构建(build-release.yml regression gate 在 windows-2025 跑 pytest)跳过
65 个纯逻辑测试——buffer 写入/ANSI 生成/输入解析逻辑在 Windows 上完全无回归保障。

改动:
1. test_buffer/test_output/test_input_parser(65 测试):移除 skipif——纯逻辑、无平台调用、
   import 链安全,Windows CI 将实际执行
2. test_app_widgets/test_daemon_manager/test_daemon_manager_e2e:保留 skip(交互/daemon
   生命周期依赖 POSIX 终端/进程语义),但注释更新为准确原因(不再声称 POSIX-only)

验证:470 passed(macOS 全量回归)+ import OK + --help OK

@argszero argszero left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle 20260805-1714

改动精确:移除 3 个纯逻辑测试文件的过时 skipif(buffer/ANSI/input-parser 无平台调用,import 链已由 #401 None 保护),另 3 个保留 skip 但注释修正为准确原因。macOS 全量 470 passed,CI 全绿。Windows CI 回归保障从 0 → 65 测试,方向与 v0.2.2 Windows 支持一致。

@argszero argszero left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle 20260805-1720

复审 diff:移除 skipif 的三个文件(test_buffer/test_output/test_input_parser)确认纯逻辑、无平台调用残留;保留 skip 的三个文件注释已准确反映 POSIX 依赖。CI test pass(34s)。与 cycle 20260805-1714 的 LGTM 连续,无 ❌ 间隔。LGTM 2/3。

@argszero argszero left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ LGTM — cycle 20260805-1722

第三轮独立 review:改动范围精确(仅测试文件的 skipif/注释调整),无生产代码变更;470 passed(macOS 全量)+ CI pass。连续 3 个不同 cycle 的 ✅(1714/1720/1722)且中间无 ❌——满足合并条件。

@argszero
argszero merged commit d8c51cb into master Aug 5, 2026
1 check passed
@argszero
argszero deleted the feature/win-ci-pure-logic-tests branch August 5, 2026 09:23
argszero added a commit that referenced this pull request Aug 5, 2026
#408 教训:bump 版本时遗漏 emrg/gui/package.json → 发布后发现
版本不一致 → 删 release + 删 tag + 重打 + 触发重建。

新增 tests/test_version_sync.py:从 emrg/__init__.py 取基准版本,
校验 6 处版本声明一致(pyproject / gui package.json / uv.lock /
make-installer.sh / build-runtime.sh fallback)。纯逻辑测试,
Windows CI 亦可执行(#406)。472 passed。

Co-authored-by: EMRG Evolution <emrg@argszero.dev>
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