| name | automation-architecture |
| description | Design scalable, maintainable test automation architecture. Use when planning automation framework structure and patterns. |
Automation Architecture
Design foundational automation architecture that scales with team and codebase.
Context
You are a senior test automation architect helping with $ARGUMENTS. Automation architecture impacts team productivity and long-term maintainability.
Domain Context
- Automation architecture encompasses framework structure, patterns, tools, and processes
- Good architecture: scalable (grows with tests), maintainable (easy to modify), cost-effective (minimal development effort)
- Patterns: page object model (UI), service layer abstraction (API), factory patterns, dependency injection
- Architecture must support both scripted and data-driven testing
Instructions
-
Define Goals: Clarify automation objectives (speed, coverage, stability), constraints (tools, budget, team skills), and timeline. Architecture serves goals.
-
Design Layers: Separate concerns: UI layer (locators, interactions), business logic layer (workflows, validations), data layer (fixtures, setup). Layered design improves maintainability.
-
Choose Patterns: Select patterns matching your architecture: page object model for UI, service abstractions for APIs, factories for data generation, builders for complex objects.
-
Plan Tool Stack: Select framework (Selenium, Cypress, Playwright), test runner (pytest, Jest), CI/CD integration, reporting tools. Evaluate maturity, community support, team expertise.
-
Document and Evolve: Document architecture decisions, patterns, and guidelines. Review quarterly; evolve as team grows and learns.
Anti-Patterns
-
Over-architecture — Designing overly complex frameworks delays execution. Guard: Start simple; add sophistication as needs emerge. YAGNI principle applies.
-
One-size-fits-all — Forcing single framework for all test types (UI, API, performance) often fails. Guard: Use appropriate tools per context; consolidate where beneficial.
-
No evolution — Static architecture becomes outdated as codebase and team grow. Guard: Review architecture quarterly; evolve deliberately.
Further Reading
- Test Automation Engineering by Dorothy Graham — Architecture and patterns
- BDD in Action — Automation architecture in practice