๐ E2E Testing Agent Specification¶
๐ฏ Purpose¶
The E2E Testing Agent is responsible for:
End-to-end cross-service scenario testing and complete user journey validation across the full stack โ ensuring that real-world user flows work correctly from frontend interaction through backend processing to infrastructure response.
While unit tests validate isolated logic and contract tests validate API boundaries, E2E tests validate that the entire system works together as users expect. The E2E Testing Agent guarantees that:
- โ Complete user journeys are tested across all layers (UI โ API โ services โ database โ infrastructure)
- ๐ Cross-service interactions are validated in realistic environments
- ๐ Test results cover role-specific, edition-specific, and tenant-specific user flows
- ๐งช Staging and release candidate environments are journey-validated before production
- ๐ Every E2E test is traceable to a business scenario, user story, or acceptance criterion
๐งฑ What Sets It Apart from Other QA Agents?¶
| Agent | Primary Role |
|---|---|
| ๐งช Test Automation Engineer | Orchestrates and runs tests across CI/CD pipelines |
| ๐ Contract Testing Agent | Validates API contracts between producers and consumers |
| ๐ Test Coverage Validator | Measures test coverage gaps |
| ๐ E2E Testing Agent | Validates complete user journeys across the full stack |
| ๐ Bug Investigator | Diagnoses root causes of failures |
๐งญ Role in Platform¶
The E2E Testing Agent operates at the highest level of the testing pyramid, validating that all layers integrate correctly for real user workflows.
๐ Positioning Diagram¶
flowchart LR
Frontend[Frontend Developer Agent]
Backend[Backend Developer Agent]
QA[QA Engineer Agent]
E2E[E2E Testing Agent]
TestAuto[Test Automation Engineer Agent]
Release[Release Manager Agent]
Frontend --> E2E
Backend --> E2E
QA --> E2E
E2E --> TestAuto
E2E --> Release
The E2E Testing Agent is the final validation gate that confirms all layers of the platform work together before release.
๐ง Why It Exists¶
Without this agent, the factory would suffer from:
- Integration blind spots โ individual services pass tests but fail when combined
- User journey regressions โ critical business flows break silently across releases
- Environment-specific failures โ staging issues discovered only after production deployment
- Cross-service data flow bugs โ data transformation errors between layers go undetected
- Confidence gaps โ release managers lack evidence that full user scenarios are working
This agent makes full-stack validation automated, traceable, and continuous.
๐ Triggering Events¶
| Event | Description |
|---|---|
feature_development_completed |
A feature spanning multiple services is marked complete by development agents |
deployment_to_staging |
Services are deployed to a staging environment, ready for integration validation |
release_candidate_ready |
A release candidate is assembled and requires full journey validation before promotion |
cross_service_change_detected |
Changes detected in multiple services that interact in user journeys |
qa_plan_e2e_triggered |
QA Engineer Agent explicitly requests E2E validation for specific scenarios |
๐ Responsibilities and Deliverables¶
โ Core Responsibilities¶
| Responsibility | Description |
|---|---|
| Define User Journey Test Scenarios | Maps business requirements and user stories to executable E2E test scenarios |
| Orchestrate Full-Stack Test Execution | Coordinates browser automation, API calls, service interactions, and database assertions |
| Validate Cross-Service Data Flow | Ensures data created in one service is correctly processed and available in downstream services |
| Test Role-Based User Journeys | Executes journeys under different user roles (Admin, Guest, Manager) with appropriate identity injection |
| Test Edition-Specific Journeys | Validates that edition-specific features and restrictions work correctly in E2E flows |
| Capture Visual Evidence | Records screenshots, videos, and HAR files during E2E execution for debugging and audit |
| Monitor Performance During Journeys | Tracks page load times, API response latencies, and rendering performance during E2E runs |
| Emit Journey Validation Reports | Produces detailed reports showing step-by-step results for each user journey |
| Integrate with Quality Gates | Blocks releases when critical user journeys fail |
Emit E2EValidationCompleted Event |
Signals downstream agents that E2E validation is finished with comprehensive status |
๐ค Output Deliverables¶
| Output Type | Format | Description |
|---|---|---|
e2e-test-suite |
.spec.ts, .feature, .cs |
Generated E2E test scenarios using Playwright, Cypress, or SpecFlow |
journey-validation-report |
.md, .json |
Step-by-step results for each user journey with pass/fail status |
visual-evidence/ |
.png, .mp4, .har |
Screenshots, recordings, and network traces from E2E execution |
performance-baseline.json |
.json |
Timing metrics captured during journey execution for trend analysis |
execution-metadata.json |
.json |
Trace-tagged metadata of the E2E validation run |
๐ Example: journey-validation-report.md¶
### ๐ E2E Journey Report โ Invoice Creation to Payment
๐ Trace: e2e-2026-0329-invoice-flow
๐ท๏ธ Environment: staging
๐ญ Role: FinanceManager | Edition: enterprise
#### Journey Steps:
| Step | Action | Expected | Actual | Status |
| ---- | ------------------------------- | ------------------------- | ------------------------- | ------ |
| 1 | Login as FinanceManager | Dashboard loads | Dashboard loaded (1.2s) | โ
|
| 2 | Navigate to Invoice Creation | Form renders | Form rendered (0.8s) | โ
|
| 3 | Submit new invoice | Invoice saved, ID returned| Invoice #4821 created | โ
|
| 4 | Verify invoice in list | Invoice appears in grid | Invoice visible | โ
|
| 5 | Process payment | Payment confirmation | Payment confirmed | โ
|
| 6 | Verify notification sent | Email notification logged | โ Notification not found | โ |
โ Failure: NotificationService did not process the InvoicePaymentCompleted event
๐ Action: Investigate message bus delivery between BillingService and NotificationService
๐ค Collaboration Patterns¶
๐ Direct Agent Collaborations¶
| Collaborating Agent | Interaction Summary |
|---|---|
| ๐ค QA Engineer Agent | Defines E2E test strategy, approves journey scenarios, reviews validation reports |
| โ๏ธ Test Automation Engineer Agent | Executes E2E test suites within CI/CD pipelines and manages test infrastructure |
| ๐ฅ๏ธ Frontend Developer Agent | Provides UI component structure, page routes, and interaction patterns for test generation |
| ๐ง Backend Developer Agent | Provides API endpoints, event flows, and service interaction maps used in journey definitions |
| ๐ง DevOps Engineer Agent | Provisions staging environments and manages test infrastructure for E2E execution |
| ๐ฆ Release Manager Agent | Consumes E2E validation results as release gate criteria |
๐ฌ Events Emitted & Consumed¶
| Event Name | Role |
|---|---|
feature_development_completed |
๐ Consumed โ triggers E2E scenario generation for the feature |
deployment_to_staging |
๐ Consumed โ triggers full E2E suite execution in staging |
release_candidate_ready |
๐ Consumed โ triggers release validation E2E run |
E2EValidationCompleted |
โ Emitted โ signals pass/fail to Release Manager and QA agents |
JourneyFailureDetected |
โ Emitted โ triggers investigation by Bug Investigator Agent |
๐งญ Coordination Flow¶
sequenceDiagram
participant DevOps as DevOps Engineer Agent
participant E2E as E2E Testing Agent
participant TestAuto as Test Automation Engineer
participant QA as QA Engineer Agent
participant Release as Release Manager Agent
DevOps->>E2E: deployment_to_staging
E2E->>E2E: Generate journey test scenarios
E2E->>TestAuto: Execute E2E test suite
TestAuto->>E2E: Return test results
E2E->>QA: Publish journey validation report
E2E->>Release: Emit E2EValidationCompleted
๐ง Memory and Knowledge¶
The E2E Testing Agent maintains a journey-centric knowledge base to support:
- ๐ Reusable user journey definitions across modules and tenants
- ๐ Performance baselines for journey timing regression detection
- ๐ Historical journey pass/fail rates for trend analysis
- ๐ง Cross-service interaction maps derived from past executions
๐งฉ Memory Components¶
| Memory Store | Content |
|---|---|
| ๐ Journey Definition Registry | Canonical user journey definitions mapped to business scenarios and user stories |
| ๐ Execution History Store | Past E2E results indexed by journey, environment, role, and edition |
| ๐ง Interaction Map Index | Service-to-service call graphs observed during E2E execution |
| ๐ Performance Baseline Cache | Timing benchmarks for each journey step, used for regression detection |
| ๐ Failure Pattern Library | Known E2E failure patterns (timeout, missing data, event delivery issues) |
๐ Example Memory Entry¶
{
"journeyId": "invoice-creation-to-payment",
"environment": "staging",
"role": "FinanceManager",
"edition": "enterprise",
"status": "Failed",
"failedStep": "Verify notification sent",
"rootCause": "Event delivery timeout between BillingService and NotificationService",
"executedAt": "2026-03-29T14:30:00Z",
"traceId": "e2e-2026-0329-invoice-flow",
"totalDurationMs": 12450
}
โ Validation Mechanisms¶
๐ What Is Validated?¶
| Component | Validation Criteria |
|---|---|
| UI Rendering | Pages load correctly, interactive elements are visible and functional |
| API Responses | Backend APIs return expected data with correct status codes during the journey |
| Cross-Service Events | Events published by one service are consumed and processed by downstream services |
| Data Consistency | Data created in one step is correctly available and transformed in subsequent steps |
| Role-Based Access | Journeys enforce correct access control โ unauthorized steps are properly rejected |
| Performance Thresholds | Journey steps complete within acceptable time bounds; regressions from baselines are flagged |
| Visual Integrity | Screenshots compared against baselines for unexpected UI regressions (optional visual diff) |
๐งช Validation Workflow¶
flowchart TD
Start[E2E Trigger Received]
LoadJourneys[Load journey definitions for scope]
ProvisionEnv[Verify staging environment readiness]
ExecuteJourneys[Execute journeys with browser + API automation]
ValidateSteps[Validate each step: UI + API + data + events]
CaptureEvidence[Capture screenshots, videos, HAR files]
MeasurePerformance[Compare timing against baselines]
StatusCheck{All Journeys Passed?}
EmitSuccess[Emit E2EValidationCompleted โ
]
EmitFailure[Emit JourneyFailureDetected โ]
Start --> LoadJourneys --> ProvisionEnv --> ExecuteJourneys
ExecuteJourneys --> ValidateSteps --> CaptureEvidence --> MeasurePerformance --> StatusCheck
StatusCheck -->|Yes| EmitSuccess
StatusCheck -->|No| EmitFailure
๐ Process Flow¶
flowchart TD
Start([E2E Testing Agent Activated])
LoadScenarios[Load user journey definitions]
ResolveContext[Resolve role, edition, tenant context]
SetupBrowser[Initialize browser automation โ Playwright]
SetupAPI[Configure API clients with auth tokens]
ExecuteSteps[Execute journey steps sequentially]
AssertResults[Assert UI state, API responses, data flow]
CaptureArtifacts[Save screenshots, videos, HAR, logs]
GenerateReport[Create journey validation report]
EmitEvent[Emit E2EValidationCompleted or JourneyFailureDetected]
UpdateMemory[Store results and update baselines]
End([Finish])
Start --> LoadScenarios --> ResolveContext --> SetupBrowser
SetupBrowser --> SetupAPI --> ExecuteSteps --> AssertResults
AssertResults --> CaptureArtifacts --> GenerateReport --> EmitEvent --> UpdateMemory --> End
๐ Agent Contract¶
agentId: e2e-testing
role: "Full-Stack User Journey Validator"
category: "Quality Assurance, Integration Testing, User Journey Validation"
description: >
Validates complete user journeys across frontend, backend, and infrastructure
layers. Ensures cross-service interactions work correctly in staging and
release candidate environments using browser automation and API validation.
triggers:
- feature_development_completed
- deployment_to_staging
- release_candidate_ready
inputs:
- User journey definitions (business scenarios, acceptance criteria)
- Service interaction maps
- Staging environment configuration
- Role and edition context
- Performance baselines
outputs:
- e2e-test-suite
- journey-validation-report
- visual-evidence (screenshots, videos, HAR)
- performance-baseline.json
- execution-metadata.json
- Event: E2EValidationCompleted
- Event: JourneyFailureDetected
skills:
- GenerateJourneyScenarios
- ExecuteBrowserAutomation
- ValidateCrossServiceFlow
- CaptureVisualEvidence
- MeasureJourneyPerformance
- EmitJourneyReport
- ComparePerformanceBaselines
- DetectVisualRegressions
memory:
scope: [traceId, journeyId, environment, role, edition]
stores:
- journeyDefinitionRegistry
- executionHistoryStore
- interactionMapIndex
- performanceBaselineCache
- failurePatternLibrary
validations:
- All journey steps complete successfully
- Cross-service data flow is consistent
- Performance within baseline thresholds
- Visual integrity maintained
- execution-metadata.json generated
version: "1.0.0"
status: active
๐ Summary¶
The E2E Testing Agent is the full-stack validation guardian of the ConnectSoft AI Software Factory. It ensures that:
- ๐ Complete user journeys work correctly across all layers of the platform
- ๐ Cross-service interactions are validated in realistic staging environments
- ๐ Role-specific, edition-specific, and tenant-specific flows are comprehensively tested
- ๐ธ Visual evidence and performance metrics provide rich debugging context
- ๐ง Historical journey data enables regression detection and continuous improvement
Without this agent, individual services may pass their tests but fail to deliver working user experiences. With it, every release is backed by proven, end-to-end journey validation.