running-chaos-tests
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseChaos Engineering Toolkit
Chaos Engineering Toolkit
This skill provides automated assistance for chaos engineering toolkit tasks.
本Skill可为混沌工程工具包相关任务提供自动化辅助。
Prerequisites
前提条件
Before using this skill, ensure you have:
- Test environment configured and accessible
- Required testing tools and frameworks installed
- Test data and fixtures prepared
- Appropriate permissions for test execution
- Network connectivity if testing external services
在使用本Skill前,请确保您已具备:
- 已配置且可访问的测试环境
- 已安装所需的测试工具和框架
- 已准备好测试数据和测试夹具
- 具备测试执行的适当权限
- 若测试外部服务,需确保网络连通性
Instructions
操作步骤
Step 1: Prepare Test Environment
步骤1:准备测试环境
Set up the testing context:
- Use Read tool to examine configuration from {baseDir}/config/
- Validate test prerequisites are met
- Initialize test framework and load dependencies
- Configure test parameters and thresholds
设置测试上下文:
- 使用Read工具检查{baseDir}/config/下的配置
- 验证是否满足测试前提条件
- 初始化测试框架并加载依赖项
- 配置测试参数和阈值
Step 2: Execute Tests
步骤2:执行测试
Run the test suite:
- Use Bash(test:chaos-*) to invoke test framework
- Monitor test execution progress
- Capture test outputs and metrics
- Handle test failures and error conditions
运行测试套件:
- 使用Bash(test:chaos-*)调用测试框架
- 监控测试执行进度
- 捕获测试输出和指标
- 处理测试失败和错误情况
Step 3: Analyze Results
步骤3:分析结果
Process test outcomes:
- Identify passed and failed tests
- Calculate success rate and performance metrics
- Detect patterns in failures
- Generate insights for improvement
处理测试结果:
- 识别通过和失败的测试用例
- 计算成功率和性能指标
- 检测失败模式
- 生成优化建议
Step 4: Generate Report
步骤4:生成报告
Document findings in {baseDir}/test-reports/:
- Test execution summary
- Detailed failure analysis
- Performance benchmarks
- Recommendations for fixes
在{baseDir}/test-reports/中记录测试结果:
- 测试执行摘要
- 详细故障分析
- 性能基准
- 修复建议
Output
输出内容
The skill generates comprehensive test results:
本Skill会生成全面的测试结果:
Test Summary
测试摘要
- Total tests executed
- Pass/fail counts and percentage
- Execution time metrics
- Resource utilization stats
- 已执行的测试总数
- 通过/失败数量及占比
- 执行时间指标
- 资源使用统计
Detailed Results
详细结果
Each test includes:
- Test name and identifier
- Execution status (pass/fail/skip)
- Actual vs. expected outcomes
- Error messages and stack traces
每个测试用例包含:
- 测试名称和标识符
- 执行状态(通过/失败/跳过)
- 实际结果与预期结果对比
- 错误信息和堆栈跟踪
Metrics and Analysis
指标与分析
- Code coverage percentages
- Performance benchmarks
- Trend analysis across runs
- Quality gate compliance status
- 代码覆盖率
- 性能基准
- 多轮测试趋势分析
- 质量门合规状态
Error Handling
错误处理
Common issues and solutions:
Environment Setup Failures
- Error: Test environment not properly configured
- Solution: Verify configuration files; check environment variables; ensure dependencies are installed
Test Execution Timeouts
- Error: Tests exceeded maximum execution time
- Solution: Increase timeout thresholds; optimize slow tests; parallelize test execution
Resource Exhaustion
- Error: Insufficient memory or disk space during testing
- Solution: Clean up temporary files; reduce concurrent test workers; increase resource allocation
Dependency Issues
- Error: Required services or databases unavailable
- Solution: Verify service health; check network connectivity; use mocks if services are down
常见问题及解决方案:
环境配置失败
- 错误:测试环境未正确配置
- 解决方案:验证配置文件;检查环境变量;确保依赖项已安装
测试执行超时
- 错误:测试超出最大执行时间
- 解决方案:增加超时阈值;优化慢测试用例;并行执行测试
资源耗尽
- 错误:测试过程中内存或磁盘空间不足
- 解决方案:清理临时文件;减少并发测试进程;增加资源分配
依赖项问题
- 错误:所需服务或数据库不可用
- 解决方案:验证服务健康状态;检查网络连通性;若服务宕机可使用模拟服务
Resources
参考资源
Testing Tools
测试工具
- Industry-standard testing frameworks for your language/platform
- CI/CD integration guides and plugins
- Test automation best practices documentation
- 适用于您的语言/平台的行业标准测试框架
- CI/CD集成指南和插件
- 测试自动化最佳实践文档
Best Practices
最佳实践
- Maintain test isolation and independence
- Use meaningful test names and descriptions
- Keep tests fast and focused
- Implement proper setup and teardown
- Version control test artifacts
- Run tests in CI/CD pipelines
- 保持测试的隔离性和独立性
- 使用有意义的测试名称和描述
- 保持测试快速且聚焦
- 实现适当的前置和后置处理
- 对测试工件进行版本控制
- 在CI/CD流水线中运行测试
Overview
概述
This skill provides automated assistance for chaos engineering toolkit tasks.
This skill provides automated assistance for the described functionality.
本Skill可为混沌工程工具包相关任务提供自动化辅助。
本Skill可为上述功能提供自动化辅助。
Examples
示例
Example usage patterns will be demonstrated in context.
将在上下文中演示示例使用模式。