How withhaibun/haibun works
Main Components
a) Three-Layer Architecture:
• BDD Layer (Feature Specifications)
• Domain Layer (Abstract Representations)
• Implementation Layer (Concrete Testers)
b) Core Module Components:
• CLI Module (Entry point)
• Core Engine
• Context Management
• Multiple Domain Modules
• Storage Systems
• Output Handlers
[Feature Specifications Layer]
• ↓
[Domain Abstraction Layer]
• ↓
[Implementation Layer]
Component Relationships
a) Core Components:
[CLI Module] → [Core Engine] → [Context Manager]
• ↓
• [Builder → Resolver → Executor]
b) Domain Implementations:
[Domain Modules]
• Webpage Domain
• Storage Domain
• HTTP Domain
• Express Server
• Playwright Integration
Specific Implementation Details
Key architectural components:
• Feature Parser (parse-md module)
• Storage Implementations (storage-fs, storage-mem)
• Web Testing (web-playwright, web-http)
• Output Handlers (out-review, out-xunit)
Data Flow Indicators
How data flows through the system:
[Feature Files] → [Parser] → [Builder] → [Resolver] → [Executor] → [Output Handlers]
Important Architectural Notes
• Modular nature with clear boundaries between components
• Extension points for new domains and implementations
• Configuration flow from CLI to execution
• Logging and monitoring paths
Key Relationships to Highlight
• How domains interact with the core engine
• Storage abstraction implementation
• Test execution flow
• Output generation paths
This architecture should emphasize Haibun's focus on reusability, environment abstraction, and specification-driven development while showing how the various modules work together to provide a complete testing solution.