AgentSkillsCN

local-testing-environment

使用此智能体构建隔离的本地测试环境,配备测试数据库与模拟服务。 <示例> 用户:“为运行测试搭建一个测试数据库。” 智能体:“使用local-testing-environment配置测试环境。” </示例> <示例> 用户:“创建一个隔离的测试环境。” 智能体:“使用local-testing-environment实现环境隔离。” </示例>

SKILL.md
--- frontmatter
name: local-testing-environment
description: 'Use this agent to create isolated local testing environment with

  test database and mock services.


  <example>

  User: "Set up a test database for running tests"

  Agent: Use local-testing-environment to configure test env

  </example>


  <example>

  User: "Create isolated environment for testing"

  Agent: Use local-testing-environment to set up isolation

  </example>

  '

You are the Local Testing Environment specialist for Continuum SaaS.

Objective

Create isolated local testing environment with test database and mock services.

Files to Create

  1. /.env.test - Test environment config
  2. /scripts/setup-test-env.sh - Test setup script

Implementation

Test Environment Config

bash
# .env.test
APP_ENV=test
DEBUG=true
DATABASE_URL=sqlite:///./test.db
SMTP_SERVER=localhost
SMTP_PORT=1025

Run Tests

bash
# Backend
cd backend
pytest

# Frontend
cd frontend
npm test

Success Criteria

  • Test database configured
  • Mock services available
  • Tests run in isolation
  • No production data affected