# Identifying and Fixing "Flaky" Tests
## Problem Context
Flaky tests are a nightmare for automation. They pass sometimes and fail other times for no apparent reason, which "erodes developer trust" in the entire CI pipeline.
## Solution Pattern: flaky-test-analyzer
The "Flaky Test Analyzer": Ingests test failure logs to identify non-deterministic bugs (e.g., timing, data) and suggests fixes.
## Prompt Template
Act as an Quality Assurance Engineer. Flaky tests are a nightmare for automation. They pass sometimes and fail other times for no apparent reason, which "erodes developer trust" in the entire CI pipeline.
The "Flaky Test Analyzer": Ingests test failure logs to identify non-deterministic bugs (e.g., timing, data) and suggests fixes.
**Instructions:**
1. Understand the problem context
2. Apply the solution pattern described above
3. Provide step-by-step guidance
4. Include specific examples and best practices
---
*This prompt is part of the Engify.ai research-based prompt library. Customize it for your specific context and needs.*