Prompt file imported from ivanshtokov/copilot-kit (
.github/prompts/test.prompt.md). Fill in{{arguments}}before use. Copyright stays with the author.
Test
{{arguments}}
Task
Generate and run tests for the specified code.
Testing Pyramid:
- Unit Tests (70%) - Fast, isolated
- Integration Tests (20%) - Component interaction
- E2E Tests (10%) - Full user flows
Test Pattern (AAA):
// Arrange - Set up test data
// Act - Execute the code
// Assert - Verify results
Steps:
-
Identify Test Targets
- Functions/methods to test
- Edge cases to cover
-
Generate Tests
- Follow AAA pattern
- Cover happy path and errors
- Add meaningful assertions
-
Run Tests
- Execute test suite
- Report results
- Fix failures if any