performance-testing
把性能门槛变为可自动化的 CI 护栏
可能产生高流量或费用,测试前注意别影响生产环境
用 k6 与 Lighthouse 在 CI 中做负载与前端性能测试并设预算门槛。
用 k6 做后端的负载/压测,用 Lighthouse CI 检测前端的 Web Vitals(LCP、INP、CLS),并把性能预算作为 CI 门槛来守护。在要量化性能、阻止合并时的性能回退或验证高并发表现时使用。特点是把性能指标变成自动化的 CI gates,而不是事后凭感觉评估。
▸ 展开 SKILL.md 英文原文
Test application performance with k6 load/stress/soak/spike scripts and k6 scenarios, Lighthouse CI for Web Vitals, and performance budgets as CI gates. Covers load profiles, custom metrics, bottleneck identification, and Core Web Vitals (LCP, INP, CLS). Use when: "performance test," "load test," "stress test," "soak test," "spike test," "k6," "k6 scenarios," "Lighthouse," "Web Vitals," "Core Web Vitals," "performance budget." Not for: scheduled production probes — use synthetic-monitoring; pixel-diff regressions — use visual-testing; designing tests from prod telemetry — use observability-driven-testing. Related: ci-cd-integration, qa-metrics, release-readiness.
帮我安装这个 skill:https://raw.githubusercontent.com/petrkindlmann/qa-skills/main/skills/performance-testing/SKILL.mdcurl -fsSL "https://raw.githubusercontent.com/petrkindlmann/qa-skills/main/skills/performance-testing/SKILL.md"<objective> Measure, assert, and protect application performance with budgets enforced in CI, not subjective "feels fast enough" assessments. This skill covers two domains: **load testing** (can the backend handle traffic?) and **web performance** (is the frontend fast for users?). A report that says "LCP is 3.2s" is information; a CI gate that fails the build at 2.5s is accountability. </objective> ## Quick Route | You need to... | Go to | |----------------|-------| | Test backend capacity / throughput / latency under traffic | **k6 Load Testing** → `references/recipes.md` | | Pick a load shape (constant / ramp / spike / soak) | **Load Profiles** table | | Measure frontend speed for real