Commit d522817
committed
test: add unit tests for condition-evaluator module
Add 74 tests covering the ConditionEvaluator class:
- constructor initialization and profile storage
- setQAApproval / setPhaseOutputs state management
- evaluate() for null/undefined/empty conditions
- tech stack conditions (database, frontend, backend, typescript, tests)
- database-specific conditions (supabase, RLS, migrations)
- frontend-specific conditions (react, vue, tailwind)
- workflow state conditions (QA approval, phase completion)
- composite conditions (has_any_data_to_analyze)
- negation operator (!)
- AND (&&) and OR (||) operators
- mixed operator evaluation (OR-of-ANDs)
- dot notation profile access and equality checks
- unknown condition permissive behavior
- shouldExecutePhase decision logic
- getFailedConditions for AND, OR, and mixed operators
- getSkipExplanation human-readable reasons
- evaluateAllPhases summary generation1 parent 6eaa7aa commit d522817
1 file changed
Lines changed: 541 additions & 0 deletions
0 commit comments