跳到技能内容
词映 AI导航
发现工具选型指南Skills 技能AI 快讯AI图片AI视频AI文档AI办公AI助手AI搜索AI编程AI音频AI设计AI智能体模型与开发AI学习模型评测AI提示词内容检测AI金融AI 3D扫描与识别其他工具跨境电商 AI
词映 AI导航
工具库Skills 技能
我的收藏
词映 AI导航
发现工具选型指南Skills 技能AI 快讯AI图片AI视频AI文档AI办公AI助手AI搜索AI编程AI音频AI设计AI智能体模型与开发AI学习模型评测AI提示词内容检测AI金融AI 3D扫描与识别其他工具跨境电商 AI
Skills directory/mturac/everything-openai-codex/golang-testing

Codex Write Go Table-Driven Tests with Named Subtests

Use the standard Go test framework to make boundary cases and failures easy to reproduce.

中文

Install in Codex

Use a Go module, Go toolchain, and a function that can be tested locally.

  1. Copy the pinned `.kiro/skills/golang-testing/` directory into `.agents/skills/golang-testing/` in the project.
  2. Tell Codex the function and existing test style, and ask for normal, empty, and boundary cases first.

Example task

Add named cases for leading and trailing spaces, an empty string, all spaces, and an already-normalized label in a local `NormalizeLabel` test.

What to check

A failed case shows its name and actual result, and `go test ./...` can rerun the package suite.

Original SKILL.md on GitHub · Updated 2026-11-13

Frequently asked question

When is t.Parallel appropriate for subtests?

Check that cases do not share mutable state, environment settings, or execution order before enabling parallel execution.

Related skills from this repository

  • Codex Verify Local TypeScript Scripts and Unit Tests with Bun
  • Codex Build a VS Code CodeTour with File and Line Anchors
Browse Codex skills in the Chinese directory
词映 AI 导航Skills 技能
工具分类全部工具已本地化技能选型指南AI 快讯