mobile-testing
它能做什么
这项技能检查项目测试的移动端覆盖范围,包括屏幕尺寸、触摸操作和真实设备。适用于希望捕捉只在手机和平板上出现的问题的团队。
适用场景
- ✓当你想确认项目是否测试了移动端布局的时候。
- ✓当页面在桌面端看起来正常,但在手机上出问题,而你希望测试能捕捉到的时候。
- ✓当你在设置测试自动化,并希望包含移动设备预设的时候。
技能链接
https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/mobile-testing/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请帮我检查网站是否有针对手机屏幕的测试,如果没有,请添加一些。”
每周 5 个新技能,1 分钟读完。
工作原理
智能体会查找移动设备设置、视口测试或项目中的相关说明。如果缺失,它会为关键用户流程添加使用移动设备预设的 Playwright 测试。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Test on real mobile devices and viewports
More than 55% of global web traffic comes from mobile devices. Mobile browsers have different rendering engines, different font rendering, limited memory, real touch events that differ from mouse events, and system UI (notch, home indicator, keyboard) that intrudes on your layout. Issues like sticky hover states, touch target sizes, and keyboard layout shifts only appear on real devices.
Quick Reference
- Desktop DevTools device emulation catches layout issues but not real touch behavior
- Test on at least one Android (Chrome) and one iOS (Safari) real device
- Test common viewport breakpoints: 375px (iPhone SE), 390px (iPhone 14), 768px (iPad)
- Use BrowserStack or similar services for testing on devices you don't own
Check
Does this project have any mobile-specific test configurations? Check for Playwright device emulation, mobile viewport tests, or notes about mobile testing.
Fix
Add Playwright tests using mobile device presets to cover key user flows on mobile viewports.
Explain
Explain the difference between DevTools emulation and real device testing, common mobile-specific issues to test for, and how to use Playwright's device emulation.
Code Review
Review tests, CI workflows, and enforcement points related to Test on real mobile devices and viewports. Flag exact gaps where the rule is not automatically verified or where failures do not block regressions.
For full implementation details, code examples, and framework-specific guidance,
see references/rule.md.
Rule page: https://frontendchecklist.io/rules/testing/mobile-testing
常见问题
只做桌面设备模拟够用吗?
这项技能指出,模拟能发现布局问题,但无法验证真实的触摸操作,因此仍建议使用真实设备。
它建议测试哪些屏幕尺寸?
这项技能提到 375、390 和 768 像素宽度是常见的断点,值得测试。
我可以测试我没有的设备吗?
可以。这项技能提到了 BrowserStack 等服务可以提供这种测试。
详情
作者的原始描述
Use when reviewing CI coverage, automated checks, or test strategy related to Test on real mobile devices and viewports. Focus on whether the rule is continuously verified, not just documented.
热度
- GitHub 星标
- 75k
- 排名
- #2940
- 许可证
- MIT
- 更新时间
- 2026/10/31
评论
- …
同一仓库的更多技能
frontendchecklist
75k使用命令行工具,依据 380 多条关于无障碍、速度、SEO 和安全的规则,检查前端代码和线上页面。
frontend-checklist-global
75k依据全部 386 条 Front-End Checklist 规则审查前端项目,并为发现的每个问题给出具体修复方法。
404-page
75k检查你的页面缺失提示是否提供有用的链接,并返回真正的 404 状态,帮助迷路的访客找到方向。
about-page
75k审查你的网站是否有清晰的关于页面,说明由谁运营,以建立访客和搜索引擎的信任。