lint: add tests for three caption rules that have none
维护者通常 1 天内回复
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 85/100
- Issue 类型
- 重构
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- bun, typescript
- 领域
- testing-qa
调研方向
这三条规则定义在 packages/lint/src/rules/captions.ts 的第 90、171 和 212 行;测试应放在 packages/lint/src/rules/captions.test.ts 中,与现有测试放在一起。先阅读每条规则的触发条件,然后编写一个会触发它的 composition,以及一个相近但不应触发的变体,并断言代码和严重级别。当 caption_transcript_not_inline、caption_textshadow_on_group_container 和 caption_fittext_scale_mismatch 各自都有正向和反向测试,并且 bun run --cwd packages/lint test 通过、没有修改规则时,即完成。
由索引模型根据 Issue 内容生成。
描述
Problem
These lint rules have no test that mentions their code, so a change that breaks them would go unnoticed:
| Code | Severity | Defined at |
|---|---|---|
caption_transcript_not_inline |
error | packages/lint/src/rules/captions.ts:90 |
caption_textshadow_on_group_container |
warning | packages/lint/src/rules/captions.ts:171 |
caption_fittext_scale_mismatch |
warning | packages/lint/src/rules/captions.ts:212 |
Tests go in packages/lint/src/rules/captions.test.ts.
Proposed solution
Add tests to the matching *.test.ts file next to each rule, following the style of the other tests in that file. For each rule, add at least:
- one composition that triggers the finding, asserting the code and severity, and
- one similar composition that should not trigger it.
Read the rule's code first: the condition it checks tells you what the minimal triggering composition looks like.
Acceptance criteria
- Each code above is asserted by at least one positive and one negative test.
bun run --cwd packages/lint testpasses.- No rule behaviour changes. If writing a test shows a rule misbehaving, note it in the PR or open a separate issue rather than changing the rule in the same PR.
- 主要语言
- TypeScript
- 星标
- 54.1k
- 派生
- 4.9k
- 平均合并
- 8 小时 41 分钟
- 30 天内合并 PR
- 723
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
heygen-com/hyperframes 的其他 Issue
-
desktop-candidate difficulty/easy enhancement good first issue help wanted triage/ready
难度 2/5 1-3 小时 新手友好度 85/100
heygen-com/hyperframes#5582 · 1 条评论 ·
维护者通常 1 天内回复
-
Studio: press ? to open the keyboard shortcuts panel可能已有人在做 @B-Payal 今天认领。 未关闭desktop-candidate difficulty/easy enhancement good first issue help wanted triage/ready
难度 2/5 1-3 小时 新手友好度 82/100
heygen-com/hyperframes#5580 · 1 条评论 ·
维护者通常 1 天内回复
-
remotion-to-hyperframes: Easing.cubic is mapped to power3 (quartic); cubic is power2可能已有人在做 @user-github-me 于 1 天前认领。 未关闭difficulty/easy documentation help wanted triage/ready
难度 1/5 1 小时以内 新手友好度 88/100
heygen-com/hyperframes#5538 · 1 条评论 ·
维护者通常 1 天内回复
-
`hyperframes docs examples` lists templates that don't exist可能已有人在做 @Muhtasim-Munif-Fahim 于 4 天前认领。 未关闭bug difficulty/easy help wanted triage/ready
难度 2/5 1-3 小时 新手友好度 82/100
heygen-com/hyperframes#5393 · 1 条评论 ·
维护者通常 1 天内回复
-
gcp-cloud-run image pins Chrome 148, which drops `background-clip: text` glyphs inside layered children; the CLI's Chrome 152 paints them可能已有人在做 @user-github-me 于 5 天前认领。 未关闭bug difficulty/medium triage/ready
难度 1/5 1 小时以内 新手友好度 84/100
heygen-com/hyperframes#5117 ·
维护者通常 1 天内回复
查看 heygen-com/hyperframes 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 75/100
apollographql/apollo-client#13493 ·
维护者通常 1 天内回复
-
Custom hosts written as trailing-dot FQDNs (`host.local.`) aren't detected as local backends可能已有人在做 @roboomp 今天认领。 未关闭bug prio:p2 providers triaged
难度 2/5 1-3 小时 新手友好度 82/100
can1357/oh-my-pi#15798 · 3 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 62/100
code-yeongyu/oh-my-openagent#10172 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 70/100
PDFCraftTool/pdfcraft#189 ·
-
Add the Yahoo chart API duplicate last-day row (yfinance#573) to incidents.md (about 1 hour)可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭data docs good first issue
难度 1/5 1 小时以内 新手友好度 80/100
pacocartones/market-data-sanity-checker#160 ·
维护者通常 1 天内回复