Skip to content

src/ 与 bulk-action-dispatch.test.ts 里 4 条「见 metadata-references.test.ts 的某守卫」的注释,指向的守卫已随 #814 拆分搬家(需多跳一次) #931

Description

@yinlianghui

Restart-when: any PR touches one of the files named below — fix that file's pointer as a declared rider
Restart-touch: src/views/opportunity.view.ts, src/views/task.view.ts, test/bulk-action-dispatch.test.ts

观察类发现,由 #814 的按族拆分(PR #930)产生。不影响任何用户、不影响任何 CI 门,纯粹是代码注释里的指路精度问题。

现状

#814 把 test/metadata-references.test.ts 按族拆成四个文件后,仓里有 4 条注释仍写着「见 metadata-references.test.ts 的某守卫」,而它们各自点名的那条守卫已经搬进了兄弟文件:

位置 注释指的守卫 现在实际在哪
src/views/opportunity.view.ts:311 dashboard 为什么可以对 close_date 开窗(#460) test/action-references.test.ts(dashboard date ranges)
src/views/task.view.ts:174 扫 /\{([^{}]+)\}/ 的 author-time filter-token 守卫 test/view-references.test.ts(filter template tokens)
src/dashboards/service.dashboard.ts:72 「dateRange 还不安全时会红」的那条守卫 test/action-references.test.ts(dashboard date ranges)
test/bulk-action-dispatch.test.ts:86 every rowAction / bulkAction names a defined action test/action-references.test.ts(list-level action references)

影响与已有缓解

指向的文件仍然存在,所以这不是断链:test/metadata-references.test.ts 顶部保留了一节 SPLIT BY FAMILY (#814),逐族列出三个兄弟文件各自持有的 describe 全名。跟着注释走的读者会落到那张表上,再一跳就能定位。代价是多一跳,不是找不到。

为什么没在 PR #930 里顺手改

#814 的派发裁定明确划了范围:纯 test/ 重构单,不动 src/,且 test/bulk-action-dispatch.test.ts 不动。这 4 条改动全部落在被排除的范围里,属于典型的「顺手优化」,因此按 Prime Directive #10 单独登记,由 PM 分诊。

建议

四处都是纯注释单行改动,把 metadata-references.test.ts 换成实际的兄弟文件名即可,零测试语义影响。可以并入任何后续碰这些文件的 PR,也可以做一个独立的注释修正单。不建议为此单独起一轮 CI —— 严格来说它现在也不算错,只是不够精确。

(登记为 observation-class:今天没有任何用户或 CI 会碰到它。)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions