Launcher tests: "uninstall.exe is the small restorer" uses a size ratio that depends on the payload and toolchain

未關閉 適合新手
#234 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

維護者通常 1 天內回覆

還沒有人認領這個 Issue。

評估

難度
2/5
預估耗時
1-3 小時
新手友好度
74/100
Issue 類型
缺陷
描述清晰度
描述清楚
活躍度
活躍
技術堆疊
python
領域
testing

研究方向

打開 clean/installer/tests/run_launcher_tests.py 中第 328 行附近,閱讀 "uninstall.exe 是小型 restorer,而不是 launcher" 檢查,以及產生測試 payload 和內嵌 restorer 的輔助函式。閱讀內嵌 restorer 是如何建置和儲存的,以便將寫出的 uninstaller 與其位元組或版本資源進行比較,並保留一個負向案例,證明完整 launcher 的副本仍然會失敗。完成的樣子是:在 MSVC static-runtime 建置上,測試套件通過且大小比例消失;執行 launcher 測試檔來確認。

由索引模型根據 Issue 內容生成。

描述

bug build

The launcher suite check "uninstall.exe is the small restorer, not the launcher"
(clean/installer/tests/run_launcher_tests.py, around line 328) passes only if the uninstaller written into the game is
smaller than a quarter of the launcher. With the suite's small test payload and an MSVC build (static C runtime), the
restorer is about a third of the launcher (about 4.1 MB vs 11.8 MB), so the check fails although the right program
(the embedded restorer, not a copy of the launcher) was written. The ratio depends on how big the payload is and on
the toolchain, not on the uninstall logic.

Fix: identify the restorer directly instead of by size. For example compare the written uninstaller with the embedded
restorer's bytes or version resource, or compare against the launcher's size minus its payload, or use a fixed upper
bound for the restorer. Keep a check that a copy of the full launcher would fail.

Found while working on #224 (launcher uninstall checks, #219); not part of that fix.

主要語言
C++
星號
12
分支
2
平均合併
3 小時 10 分鐘
30 天內合併 PR
171

環境準備

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

phantoslayer21/wronggpu 的其他 Issue

查看 phantoslayer21/wronggpu 的全部 Issue

相似的 Issue

更多 C++ Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。