2.1 KiB
2.1 KiB
description
| description |
|---|
| Standard workflow for implementing new features, including testing, verification, and documentation updates. |
Feature Implementation & Verification Workflow
Follow this process whenever a new feature is requested.
1. Implementation Phase
- Analyze Request: Understand the user's requirements.
- Plan Changes: Create or update the
implementation_plan.md. - Execute: Write the code to implement the feature.
2. Verification Phase (E2E Testing)
Once the feature is implemented, you must verify it works as expected.
- Run Existing Tests: Ensure no regressions.
npx playwright test - Manual Verification: If Playwright tests are not sufficient or applicable yet, perform manual verification steps (or use the browser tool to simulate it).
- Fix Bugs: If any issues are found (either in automated tests or manual verification), fix them immediately. Repeat this step until the feature is stable.
3. Documentation Phase
After the feature is stable and working:
- Update Requirements: Modify
specs/requirements.mdto reflect the newly added functionality and any changes to existing logic. This is the source of truth. - Update Test Plan:
- File:
specs/gymflow-test-plan.md - Action: Update this file with new test scenarios. Use the Playwright-test-generator agent to help identify gaps or create new detailed scenarios based on the updated requirements.
- File:
4. Test Generation Phase
- Generate New Tests:
- Agent: Use the
playwright-test-generatoragent. - Workflow:
- Invoke the agent.
- Provide it with the updated
specs/requirements.mdandspecs/gymflow-test-plan.md. - Ask it to generate Playwright tests for the new scenarios.
- File Path Convention:
tests/<feature-name>/<scenario>.spec.ts. - Verify: Ensure the new tests pass reliably.
- Agent: Use the
5. Finalize
- Cleanup: Remove any temporary debug logs or unused files.
- Notify User: Inform the user that the feature is complete, verified, and documented.