When to Apply: Reference when writing BDD-style tests with Jasmine, using spies for mocking, or setting up Jasmine with Karma for browser-based testing. Triggers on "Jasmine", "jasmine.createSpy", "toHaveBeenCalled", "jasmine test".
Playbook Deep Dive (10 sections): §1 Project Setup & Configuration · §2 Spies — Complete API · §3 Async Testing Patterns · §4 Custom Matchers · §5 Test Organization — Suites & Context · §6 Mocking Fetch & Modules · §7 Browser Testing with Karma · §8 CI/CD Integration · §9 Debugging Table · §10 Best Practices
The agent loads from 2 on-demand reference files (advanced-patterns.md, playbook.md) containing detailed implementation guides, cloud integration patterns, debugging tables, and language-specific best practices.