Token导航 LogoToken导航

Agent Skill · 研究检索

testing-builder(测试构建器)

用于辅助测试设计、自动化测试、用例整理和回归验证。它适合让 Agent 编写单元测试、端到端测试、测试计划或根据失败日志定位问题。使用时需要确认项目测试框架、运行命令和夹具数据,避免为了通过测试而改坏真实逻辑;涉及浏览器或外部服务时,应区分本地模拟、测试环境和生产环境。

testing-builder 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为接触敏感数据;许可证为 MIT,第三方扫描已通过,按安装量在研究检索类的 73,675 个 Skill 里排第 48,434。

总安装 689周安装 29GitHub Stars 14下载 241核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
MIT

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:testing-builder(测试构建器)
来源仓库:https://github.com/jackspace/claudeskillz
仓库路径:skills/testing-builder
安装命令:
npx skills add https://github.com/jackspace/claudeskillz --skill testing-builder
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/jackspace/claudeskillz --skill testing-builder

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

用于快速生成测试脚手架和基础代码模板。适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。适合初始化新项目测试目录结构及配置文件。支持多种语言和框架的测试项目类型适配。应根据实际需求选择具体实现方式和技术组合。

testing-builder 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

来源仓库内路径:skills/testing-builder

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/jackspace/claudeskillz --skill testing-builder;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

testing-builder 怎么安装?

在终端执行 npx skills add https://github.com/jackspace/claudeskillz --skill testing-builder。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

testing-builder 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

testing-builder 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

testing-builder 是免费的吗?

来源标注的许可证是 MIT。本站不代收任何费用,也不托管安装包;能否商用、要不要署名,以许可证原文为准。

testing-builder 用的人多吗?

公开数据是累计安装 689 次,近一周安装 29 次,下载 241 次,GitHub 14 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

testing-builder 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 3 个目录同时收录,说明这个 Skill 流传比较广。
  • 许可证明确为 MIT,商用和分发边界好判断。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。
  • 需要许可证清楚、并且有第三方扫描结果的团队项目。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
testing-builder

测试构建器 · 本页

68914接触敏感数据MIT通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Testing Builder

Purpose

Automatic test generation that learns your testing style. Eliminates the ADHD barrier to testing by making it effortless:

  1. Analyzes code to understand what needs testing
  2. Recalls your testing patterns from memory
  3. Generates comprehensive test suite
  4. Ensures all edge cases covered
  5. Saves testing patterns for future

For ADHD users: Zero friction - tests created instantly without manual effort. For all users: Comprehensive coverage without the tedious work. Learning system: Gets better at matching your testing style over time.

Activation Triggers

  • User says: "write tests", "test this", "add tests", "coverage"
  • After fixing bug: "create regression test"
  • Code review: "needs tests"
  • User mentions: "unit test", "integration test", "E2E test"

Core Workflow

1. Analyze Code

Step 1: Identify what to test

// Example: Analyzing a function
function calculateDiscount(price, discountPercent, customerType) {
  if (customerType === 'premium') {
    discountPercent += 10;
  }
  return price * (1 - discountPercent / 100);
}

// Identify:
- Function name: calculateDiscount
- Parameters: price, discountPercent, customerType
- Logic branches: premium vs non-premium
- Edge cases: negative values, zero, boundary conditions
- Return type: number

Step 2: Determine test type needed

  • Unit test: Pure functions, utilities, components
  • Integration test: Multiple components working together, API endpoints
  • E2E test: Full user workflows, critical paths
  • Regression test: Specific bug that was fixed

2. Recall Testing Patterns

Query context-manager for:

search memories:
- Type: PREFERENCE, PROCEDURE
- Tags: testing, test-framework, test-style
- Project: current project

What to recall:

  • Test framework (Jest, Vitest, Pytest, etc.)
  • Assertion style (expect, assert, should)
  • Test structure (describe/it, test blocks)
  • Mocking patterns (jest.mock, vi.mock)
  • Coverage requirements
  • File naming conventions

Example memory:

PREFERENCE: Testing style for BOOSTBOX
- Framework: Vitest
- Assertion: expect()
- Structure: describe/it blocks
- Coverage: Minimum 80%
- File naming: {filename}.test.js

3. Generate Test Suite

Unit Test Template:

import { describe, it, expect } from 'vitest';
import { calculateDiscount } from './discount';

describe('calculateDiscount', () => {
  describe('basic calculations', () => {
    it('should calculate discount correctly for regular customers', () => {
      const result = calculateDiscount(100, 10, 'regular');
      expect(result).toBe(90);
    });

    it('should add bonus discount for premium customers', () => {
      const result = calculateDiscount(100, 10, 'premium');
      expect(result).toBe(80); // 10% + 10% bonus
    });
  });

  describe('edge cases', () => {
    it('should handle zero discount', () => {
      const result = calculateDiscount(100, 0, 'regular');
      expect(result).toBe(100);
    });

    it('should handle 100% discount', () => {
      const result = calculateDiscount(100, 100, 'regular');
      expect(result).toBe(0);
    });

    it('should handle zero price', () => {
      const result = calculateDiscount(0, 10, 'regular');
      expect(result).toBe(0);
    });
  });

  describe('invalid inputs', () => {
    it('should handle negative price', () => {
      const result = calculateDiscount(-100, 10, 'regular');
      expect(result).toBeLessThan(0);
    });

    it('should handle invalid customer type', () => {
      const result = calculateDiscount(100, 10, 'unknown');
      expect(result).toBe(90); // Falls back to regular
    });
  });
});

Integration Test Template (API endpoint):

import { describe, it, expect, beforeAll, afterAll } from 'vitest';
import request from 'supertest';
import { app } from './app';
import { db } from './db';

describe('POST /api/users', () => {
  beforeAll(async () => {
    await db.connect();
  });

  afterAll(async () => {
    await db.disconnect();
  });

  it('should create a new user', async () => {
    const response = await request(app)
      .post('/api/users')
      .send({
        email: 'test@example.com',
        name: 'Test User'
      });

    expect(response.status).toBe(201);
    expect(response.body).toHaveProperty('id');
    expect(response.body.email).toBe('test@example.com');
  });

  it('should reject duplicate email', async () => {
    await request(app).post('/api/users').send({
      email: 'duplicate@example.com',
      name: 'User 1'
    });

    const response = await request(app)
      .post('/api/users')
      .send({
        email: 'duplicate@example.com',
        name: 'User 2'
      });

    expect(response.status).toBe(409);
    expect(response.body.error).toContain('already exists');
  });

  it('should validate required fields', async () => {
    const response = await request(app)
      .post('/api/users')
      .send({
        name: 'No Email'
      });

    expect(response.status).toBe(400);
    expect(response.body.error).toContain('email');
  });
});

E2E Test Template (Playwright):

import { test, expect } from '@playwright/test';

test.describe('User Login Flow', () => {
  test('should login successfully with valid credentials', async ({ page }) => {
    await page.goto('/login');

    await page.fill('[name="email"]', 'user@example.com');
    await page.fill('[name="password"]', 'password123');
    await page.click('button[type="submit"]');

    await expect(page).toHaveURL('/dashboard');
    await expect(page.locator('.welcome-message')).toContainText('Welcome');
  });

  test('should show error with invalid credentials', async ({ page }) => {
    await page.goto('/login');

    await page.fill('[name="email"]', 'wrong@example.com');
    await page.fill('[name="password"]', 'wrongpass');
    await page.click('button[type="submit"]');

    await expect(page.locator('.error-message')).toContainText('Invalid');
    await expect(page).toHaveURL('/login');
  });

  test('should validate required fields', async ({ page }) => {
    await page.goto('/login');

    await page.click('button[type="submit"]');

    await expect(page.locator('[name="email"]:invalid')).toBeVisible();
    await expect(page.locator('[name="password"]:invalid')).toBeVisible();
  });
});

4. Coverage Analysis

Check what's tested:

// Coverage requirements (from memory or defaults)
const requirements = {
  statements: 80,
  branches: 75,
  functions: 90,
  lines: 80
};

// Identify untested scenarios
const missing = [
  'Error handling for network failures',
  'Loading state transitions',
  'Concurrent operations',
  'Cleanup on unmount'
];

// Generate additional tests for missing coverage

5. Save Testing Patterns

After generating tests:

# Save testing style to memory
remember: Testing pattern for authentication
Type: PROCEDURE
Tags: testing, authentication, integration
Content: For auth endpoints, always test:
- Valid credentials → success
- Invalid credentials → 401
- Missing fields → 400
- Expired token → 401
- Token refresh flow

Framework-Specific Patterns

Jest/Vitest (JavaScript/TypeScript)

import { describe, it, expect, vi, beforeEach } from 'vitest';

describe('Component', () => {
  beforeEach(() => {
    vi.clearAllMocks();
  });

  it('should do something', () => {
    expect(result).toBe(expected);
  });
});

Mocking:

// Mock module
vi.mock('./api', () => ({
  fetchData: vi.fn(() => Promise.resolve({ data: [] }))
}));

// Mock implementation
const mockFn = vi.fn().mockImplementation(() => 'value');

Pytest (Python)

import pytest
from mymodule import calculate_discount

class TestCalculateDiscount:
    def test_regular_customer(self):
        result = calculate_discount(100, 10, 'regular')
        assert result == 90

    def test_premium_customer(self):
        result = calculate_discount(100, 10, 'premium')
        assert result == 80

    @pytest.mark.parametrize("price,discount,expected", [
        (100, 0, 100),
        (100, 100, 0),
        (0, 10, 0),
    ])
    def test_edge_cases(self, price, discount, expected):
        result = calculate_discount(price, discount, 'regular')
        assert result == expected

Fixtures:

@pytest.fixture
def sample_user():
    return {
        'id': 1,
        'email': 'test@example.com',
        'name': 'Test User'
    }

def test_user_creation(sample_user):
    assert sample_user['email'] == 'test@example.com'

React Testing Library

import { render, screen, fireEvent } from '@testing-library/react';
import { expect, test } from 'vitest';
import { UserList } from './UserList';

test('renders user list', () => {
  const users = [
    { id: 1, name: 'Alice' },
    { id: 2, name: 'Bob' }
  ];

  render(<UserList users={users} />);

  expect(screen.getByText('Alice')).toBeInTheDocument();
  expect(screen.getByText('Bob')).toBeInTheDocument();
});

test('handles empty user list', () => {
  render(<UserList users={[]} />);

  expect(screen.getByText('No users found')).toBeInTheDocument();
});

test('handles user click', () => {
  const handleClick = vi.fn();
  const users = [{ id: 1, name: 'Alice' }];

  render(<UserList users={users} onUserClick={handleClick} />);

  fireEvent.click(screen.getByText('Alice'));

  expect(handleClick).toHaveBeenCalledWith(users[0]);
});

Test Categories

Unit Tests

What to test:

  • Pure functions
  • Utility functions
  • Component logic
  • Class methods

Focus on:

  • Input/output correctness
  • Edge cases
  • Error conditions
  • Boundary values

Integration Tests

What to test:

  • API endpoints
  • Database operations
  • Multiple components together
  • External service integration

Focus on:

  • Component interactions
  • Data flow
  • Error propagation
  • Transaction handling

E2E Tests

What to test:

  • Critical user flows
  • Complete features
  • Multi-step processes
  • Cross-page workflows

Focus on:

  • User perspective
  • Real browser interaction
  • Full stack integration
  • Production-like environment

Regression Tests

When to create:

  • After fixing a bug
  • Preventing known issues
  • Historical problems

Structure:

describe('Regression: Bug #123 - User map undefined', () => {
  it('should handle undefined users array', () => {
    // Test that previously failed
    const result = renderUserList(undefined);
    expect(result).not.toThrow();
  });
});

Context Integration

Recall Testing Preferences

Before generating tests:

// Query context-manager
const preferences = searchMemories({
  type: 'PREFERENCE',
  tags: ['testing', project],
  recent: true
});

// Apply preferences
const testConfig = {
  framework: preferences.framework || 'vitest',
  style: preferences.style || 'describe/it',
  coverage: preferences.coverage || 80,
  naming: preferences.naming || '{name}.test.js'
};

Save Testing Patterns

After generating tests:

remember: Testing pattern for API endpoints
Type: PROCEDURE
Tags: testing, api, integration
Content: For API endpoints, always include:
1. Happy path (200/201)
2. Validation errors (400)
3. Auth errors (401/403)
4. Not found (404)
5. Server errors (500)
6. Rate limiting (429)

Learn from Feedback

If user modifies generated tests:

// Analyze what user changed
const changes = diff(generatedTest, userModifiedTest);

// Save as new pattern if significant
if (changes.significant) {
  saveMemory({
    type: 'PREFERENCE',
    content: `User prefers ${changes.pattern}`,
    tags: ['testing', 'user-preference']
  });
}

Integration with Other Skills

Error Debugger

When error-debugger fixes a bug:

Automatically invoke testing-builder
Create regression test for: {bug_scenario}
Ensure test fails before fix, passes after

Context Manager

Load testing preferences:

Query for PREFERENCE with tags: [testing, test-framework]
Apply framework, style, coverage preferences

Save new patterns:

After generating tests for new scenario
Save pattern as PROCEDURE for future reference

Code Quality Auditor

Check test quality:

After generating tests:
→ Invoke code-quality-auditor
→ Verify test coverage
→ Check for test smells
→ Ensure meaningful assertions

Quick Reference

Test Generation Checklist

✅ Happy path covered ✅ Edge cases tested ✅ Error conditions handled ✅ Invalid inputs validated ✅ Boundary values checked ✅ Async operations handled ✅ Mocks properly configured ✅ Cleanup properly done ✅ Assertions are meaningful

Common Test Patterns

ScenarioPattern
FunctionInput → Output assertions
ComponentRender → Query → Assert
APIRequest → Response → Assert
Asyncawait → Promise → Result
ErrorTry/catch → Error assertion
MockSetup → Call → Verify mock

Trigger Phrases

  • "write tests"
  • "test this"
  • "add coverage"
  • "create regression test"
  • "needs tests"

File Locations

  • Test patterns: ~/.claude-memories/ (Linux/macOS) or %USERPROFILE%\.claude-memories\ (Windows)procedures/ (tagged "testing")
  • Test preferences: ~/.claude-memories/ (Linux/macOS) or %USERPROFILE%\.claude-memories\ (Windows)preferences/ (tagged "testing")
  • Generated tests: {filename}.test.{ext} or tests/{filename}.test.{ext}

Success Criteria

✅ Tests generated in <30 seconds ✅ Comprehensive coverage (80%+ by default) ✅ All edge cases included ✅ Tests follow project style ✅ Zero manual effort required ✅ Testing patterns saved for future

平台分布

Claude Code

28.46%
按下载量换算69

windsurf

22.03%
按下载量换算53

OpenCode

20.93%
按下载量换算50

Codex

11.91%
按下载量换算29

Antigravity

9.05%
按下载量换算22

Gemini CLI

3.86%
按下载量换算9

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

继续浏览同类 Skills