Skip to content
Back to skills

Test Integration

ASecurity

执行项目集成测试流程。 当需要运行集成测试或端到端验证时使用。

  • 88 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added September 23, 2026
ai-agentstypescriptbashnodeapi

Works with

  • cli
  • api

Security analysis

A100/100

Scanned November 9, 2026

npx -y skills add fitlab-ai/agent-infra --skill test-integration --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Test Integration?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Test Integration
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/fitlab-ai-test-integration/badge)](https://www.skillsdirectory.com/skills/fitlab-ai-test-integration)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: test-integration
description: >
  执行项目集成测试流程。
  当需要运行集成测试或端到端验证时使用。
---

# 运行集成测试

执行项目的集成测试流程,进行端到端验证。

## 1. 验证构建产物

项目使用 TypeScript。`npm run test:integration` 会先运行 `npm run build`,再执行集成与端到端测试,因此无需单独重复构建。

## 2. 运行集成测试

```bash
npm run test:integration
```

该脚本先构建项目,再运行 `tests/integration/**/*.test.ts` 和 `tests/e2e/**/*.test.ts`,并启用 Node.js TypeScript strip-types 支持。

## 3. 输出结果

报告结果:
- 运行/通过/失败的测试数
- 环境问题(如有)
- 失败详情(如有)

## 失败处理

如果测试失败:
- 输出失败详情
- 检查环境问题(端口占用、服务未运行等)
- 在任务范围内且可诊断时,先检查证据并修复本次引入的问题,再运行相同测试验证;涉及范围外设计、用户数据冲突或必要授权时记录阻塞并继续独立工作。

## 后续步骤

测试通过后,建议提交变更:

> 渲染下一步前先读取 `.agents/rules/next-step-output.md`,仅为已选场景调用统一 helper,并将 stdout 填入 `{next-step-commands}`。

使用 `agent-infra-internal agent-client next-steps --skill commit` 生成本场景的 `{next-step-commands}`。

```
下一步 - 提交代码:
{next-step-commands}
```

## 注意事项

1. **前置条件**:Node.js >= 22.9.0;脚本会自动构建
2. **环境**:集成测试可能需要外部服务(数据库、API 等)
3. **超时**:集成测试通常耗时较长;请耐心等待
4. **清理**:确保测试完成后清理测试环境

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.