Frontend Testing

作者 langgenius2b65f0e89309無授權條款157K 個星標收錄於 2026年10月8日更新於 2026年10月8日儲存庫今天更新

Use when writing or changing Vitest or React Testing Library tests under `web/` or `packages/dify-ui/`, or when the user explicitly requests frontend test strategy, including evaluation of an existing strategy. Do not use for frontend code-review-only requests, general testability discussion, Python tests, or Cucumber/Playwright E2E.

AI 產生的概覽

指導撰寫或修改 Vitest 與 React Testing Library 前端測試,並遵循各套件自身的測試策略。

功能
此技能讓代理先閱讀被修改測試所屬套件的測試策略文件:web/ 對應 web/docs/test.md,packages/dify-ui/ 對應 packages/dify-ui/docs/testing.md。它不新增獨立的策略或檢查流程,而是遵循所選文件對測試邊界、環境與驗證指令的要求。它也鼓勵在補足行為覆蓋的同時同樣積極地刪除低價值測試,並要求回報已驗證的契約以及任何重要的驗證缺口。
適用情境
適用於在 web/ 或 packages/dify-ui/ 底下撰寫或修改 Vitest 或 React Testing Library 測試,或使用者明確要求前端測試策略(包括評估現有策略)時。不適用於僅做前端程式碼審查、一般可測試性討論、Python 測試或 Cucumber/Playwright 端對端測試。
執行需求
不包含指令碼,僅為說明性指示。它依賴儲存庫中存在的所引用策略文件:web/docs/test.md 與 packages/dify-ui/docs/testing.md。

Frontend Testing

Read the testing policy for the package that owns the changed tests:

  • web/: web/docs/test.md owns Web test boundaries, environments, and commands.
  • packages/dify-ui/: packages/dify-ui/docs/testing.md owns primitive test boundaries, environments, Storybook, and commands.

This skill adds no parallel policy or check sequence. Follow the selected owner's requirements, including its validation commands. Recommend deleting low-value tests as readily as adding missing behavior coverage, and report the contract verified and any material verification gap.

來源與署名

來源:langgenius/dify位於.agents/skills/frontend-testing提交2b65f0e

授權條款: 無授權條款

內容歸原作者所有。SourceWeft 從公開儲存庫中收錄這些內容。

檢舉或申請下架