·dotnet-testing-unit-test-fundamentals
</>

dotnet-testing-unit-test-fundamentals

kevintsengtw/dotnet-testing-agent-skills

.NET 單元測試基礎與 PRIMERO 原則的專門技能. 當需要建立單元測試、了解測試基礎、學習 Patrón 3A、掌握測試最佳實踐時使用. 涵蓋 PRIMERA 原則、Patrón AAA、Hecho/Teoría、測試金字塔等。

27Instalaciones·1Tendencia·@kevintsengtw

Instalación

$npx skills add https://github.com/kevintsengtw/dotnet-testing-agent-skills --skill dotnet-testing-unit-test-fundamentals

SKILL.md

| Arrange | 準備測試所需的物件、資料、Mock | 使用 const 宣告常數值,提高可讀性 | | Act | 執行被測試的方法 | 通常只有一行,呼叫被測方法 | | Assert | 驗證結果 | 每個測試只驗證一個行為 |

| Add輸入1和2應回傳3 | 測試正常輸入 | | Add輸入負數和正數應回傳正確結果 | 測試邊界條件 | | Divide輸入10和0應拋出DivideByZeroException | 測試例外情況 | | IsValidEmail輸入null值應回傳False | 測試無效輸入 | | GetDomain輸入有效Email應回傳網域名稱 | 測試回傳值 |

| Assert.Equal(expected, actual) | 驗證相等 | | Assert.NotEqual(expected, actual) | 驗證不相等 | | Assert.True(condition) | 驗證條件為真 | | Assert.False(condition) | 驗證條件為假 | | Assert.Null(object) | 驗證為 null | | Assert.NotNull(object) | 驗證不為 null | | Assert.Throws (action) | 驗證拋出特定例外 | | Assert.Empty(collection) | 驗證集合為空 | | Assert.Contains(item, collection) | 驗證集合包含項目 |

.NET 單元測試基礎與 PRIMERO 原則的專門技能. 當需要建立單元測試、了解測試基礎、學習 Patrón 3A、掌握測試最佳實踐時使用. 涵蓋 PRIMERA 原則、Patrón AAA、Hecho/Teoría、測試金字塔等。 Fuente: kevintsengtw/dotnet-testing-agent-skills.

Ver original

Datos (listos para citar)

Campos y comandos estables para citas de IA/búsqueda.

Comando de instalación
npx skills add https://github.com/kevintsengtw/dotnet-testing-agent-skills --skill dotnet-testing-unit-test-fundamentals
Categoría
</>Desarrollo
Verificado
Primera vez visto
2026-02-01
Actualizado
2026-02-18

Respuestas rápidas

¿Qué es dotnet-testing-unit-test-fundamentals?

.NET 單元測試基礎與 PRIMERO 原則的專門技能. 當需要建立單元測試、了解測試基礎、學習 Patrón 3A、掌握測試最佳實踐時使用. 涵蓋 PRIMERA 原則、Patrón AAA、Hecho/Teoría、測試金字塔等。 Fuente: kevintsengtw/dotnet-testing-agent-skills.

¿Cómo instalo dotnet-testing-unit-test-fundamentals?

Abre tu terminal o herramienta de línea de comandos (Terminal, iTerm, Windows Terminal, etc.) Copia y ejecuta este comando: npx skills add https://github.com/kevintsengtw/dotnet-testing-agent-skills --skill dotnet-testing-unit-test-fundamentals Una vez instalado, el skill se configurará automáticamente en tu entorno de programación con IA y estará listo para usar en Claude Code o Cursor

¿Dónde está el repositorio de origen?

https://github.com/kevintsengtw/dotnet-testing-agent-skills