## 2026-10-08T04:21:14Z
From: f9992164-c0e4-4f7d-ba4a-25a83a4436bf (Parent Orchestrator)
Content:
You are teamwork_preview_test_writer (E2E Testing Track Writer).
Your working directory is: c:\Projects\KieuStory\.agents\teamwork\test_writer_e2e
You MUST read c:\Projects\KieuStory\.agents\teamwork\ORIGINAL_REQUEST.md and c:\Projects\KieuStory\PROJECT.md before starting work.

Your objective:
1. Create c:\Projects\KieuStory\TEST_INFRA.md following the TEST_INFRA template in the Project Pattern:
   - Test Philosophy: Opaque-box, requirement-driven, testing F1-F13 across Tiers 1-4.
   - Feature Inventory mapping for test coverage.
   - Test Architecture & runner instructions.
2. Build an automated opaque-box test suite under c:\Projects\KieuStory\tests/ using Python (unittest or pytest):
   - Tier 1: Feature Coverage (>=5 test cases per feature for F1-F13 -> >=65 test cases):
     * F1: EP01 duration >=25m (>=1500s) and shot count >=150, 3-act structure.
     * F2: Scene 05 contains C05-A (tiểu khê), C05-B (nấm mồ sè sè / thắc mắc), C05-C (nước mắt / dấu hài in rêu).
     * F3: 0% male tears (regex check on all male character action beats in EP01 for khóc, rơi lệ, châu sa).
     * F4: Universal acting directives codified in Project Bible (Anti-male-tears, micro-expressions).
     * F5: Sweet-spot start frame protocol (Gemini Banana 720p 1280x720, zero reversed birds/motion).
     * F6: Lip-sync guard (closed lips clause present in all off-screen/distant dialogue prompts).
     * F7: 188-shot prompt registry present in gemini_banana_prompts.json and muse_ai_video_prompts.json.
     * F8: Audio crossfade concat configured as default in audio_continuity_engine / production_orchestrator.
     * F9: Continuous festival crowd ambience bed track present and integrated.
     * F10: EBU R128 loudness target -14.0 LUFS (+-0.5) and True Peak <= -1.0 dBTP.
     * F11: Web Review Studio running on port 1515, endpoints /api/shots, /api/scenes responsive.
     * F12: Automated runner run_shot.py / production_orchestrator.py CLI integration.
     * F13: Master verification and assembly validation.
   - Tier 2: Boundary & Corner Cases (>=5 test cases per feature -> >=65 test cases):
     * Edge conditions: Empty dialogue, extreme loudness inputs, missing start frames fallback, whitespace in prompt IDs, zero audio track handling, etc.
   - Tier 3: Cross-Feature Interactions (>=13 pairwise test cases):
     * Lip-sync guard + audio crossfade; Male character micro-expression + start frame resolution; Sweet-spot start frame + head-tail chaining; etc.
   - Tier 4: Real-World Application Workloads (>=7 realistic end-to-end workload test cases):
     * Full EP01 screenplay parse and duration validation; Full audio master loudness measurement simulation; Web Studio API response validation; etc.
   - Total test cases MUST exceed 150.
3. Provide a test runner script c:\Projects\KieuStory\tests\run_all_tests.py that runs the suite and reports results. Run the test suite to verify tests execute properly.
4. Once created, publish c:\Projects\KieuStory\TEST_READY.md at project root with full coverage summary and runner command.
5. Write your complete handoff report to handoff.md and send a completion message back.
