Get the FREE Ultimate OpenClaw Setup Guide →

ln-632-test-e2e-priority-auditor

Scanned
npx machina-cli add skill levnikolaevich/claude-code-skills/ln-632-test-e2e-priority-auditor --openclaw
Files (1)
SKILL.md
6.3 KB

Paths: File paths (shared/, references/, ../ln-*) are relative to skills repo root. If not found at CWD, locate this SKILL.md directory and go up one level for repo root.

E2E Critical Coverage Auditor (L3 Worker)

Specialized worker auditing E2E test coverage for critical paths (risk-based).

Purpose & Scope

  • Worker in ln-630 coordinator pipeline
  • Audit E2E Critical Coverage (Category 2: High Priority)
  • Validate E2E coverage for critical paths (Money/Security/Data Priority ≥20)
  • Validate E2E coverage for core user journeys (Priority 15-19)
  • Identify wasteful E2E tests (Usefulness Score <15)
  • Calculate compliance score (X/10)

Inputs (from Coordinator)

MANDATORY READ: Load shared/references/task_delegation_pattern.md#audit-coordinator--worker-contract for contextStore structure.

Receives contextStore with: tech_stack, testFilesMetadata, codebase_root, output_dir.

Workflow

  1. Parse Context: Extract tech stack, critical paths, user journeys, test file list, output_dir from contextStore
  2. Identify Critical Paths: Scan codebase for critical paths (Money, Security, Data)
  3. Identify Core Journeys: Identify core user journeys (multi-step flows)
  4. Check Critical Path Coverage: Check E2E coverage for critical paths (Priority >=20)
  5. Check Journey Coverage: Check E2E coverage for user journeys (Priority 15-19)
  6. Validate E2E Tests: Validate existing E2E tests (Usefulness Score >=15)
  7. Collect Findings: Record each violation with severity, location (file:line), effort estimate (S/M/L), recommendation
  8. Calculate Score: Count violations by severity, calculate compliance score (X/10)
  9. Write Report: Build full markdown report in memory per shared/templates/audit_worker_report_template.md, write to {output_dir}/632-e2e-priority.md in single Write call
  10. Return Summary: Return minimal summary to coordinator (see Output Format)

Audit Rules

1. Critical Path E2E Coverage

Rule: Every critical path MUST have E2E test

Critical Paths (Priority ≥20):

  • Money (Priority 25): Payment processing, refunds, discounts, tax calculation
  • Security (Priority 25): Login, auth, password reset, token refresh, permissions
  • Data Export (Priority 20): Reports, CSV generation, data migration

Detection:

  1. Scan codebase for critical keywords: payment, refund, login, auth, export
  2. Extract critical functions/endpoints
  3. Check if E2E test exists for each critical path
  4. Missing E2E for Priority ≥20 → CRITICAL severity

Severity:

  • CRITICAL: No E2E for Priority 25 (Money, Security)
  • HIGH: No E2E for Priority 20 (Data Export)

Recommendation: Add E2E tests for critical paths immediately

Effort: M

2. Core User Journey E2E Coverage

Rule: Multi-step critical flows MUST have E2E test

Core Journeys (Priority 15-19):

  • Registration → Email verification → First login (Priority 16)
  • Product search → Add to cart → Checkout (Priority 18)
  • File upload → Processing → Download result (Priority 15)

Detection:

  1. Identify multi-step flows in routes/controllers
  2. Check if end-to-end journey test exists
  3. Missing E2E for Priority ≥15 → HIGH severity

Severity:

  • HIGH: Missing E2E for core user journey (Priority ≥15)
  • MEDIUM: Incomplete journey coverage (only partial steps tested)

Recommendation: Add end-to-end journey tests

Effort: M-L

3. E2E Test Usefulness Validation

Rule: Every E2E test MUST justify Priority ≥15

Check: For each E2E test, calculate Usefulness Score = Impact × Probability

  • If Score <15 → Flag as "Potentially wasteful E2E"
  • Recommendation: Convert to Integration or Unit test (cheaper)

Example:

  • E2E test for "API returns 200 OK" → Impact 2, Probability 1 → Score 2 → WASTEFUL
  • E2E test for "Payment with discount calculates correctly" → Impact 5, Probability 5 → Score 25 → VALUABLE

Severity:

  • MEDIUM: E2E test with Usefulness Score <15
  • LOW: E2E test with Score 10-14 (review needed)

Recommendation: Convert low-value E2E to Integration/Unit or remove

Effort: S

Scoring Algorithm

MANDATORY READ: Load shared/references/audit_scoring.md for unified scoring formula.

Severity mapping:

  • Missing E2E for Priority 25 (Money, Security) → CRITICAL
  • Missing E2E for Priority 20 (Data Export) → HIGH
  • Missing E2E for Priority 15-19 (Core Journeys) → HIGH
  • Wasteful E2E (Score <15) → MEDIUM
  • Incomplete journey coverage → LOW

Output Format

MANDATORY READ: Load shared/templates/audit_worker_report_template.md for file format.

Write report to {output_dir}/632-e2e-priority.md with category: "E2E Critical Coverage" and checks: critical_path_coverage, user_journey_coverage, e2e_usefulness_validation.

Return summary to coordinator:

Report written: docs/project/.audit/ln-630/{YYYY-MM-DD}/632-e2e-priority.md
Score: X.X/10 | Issues: N (C:N H:N M:N L:N)

Critical Rules

  • Do not auto-fix: Report only
  • Risk-based only: Prioritize by business impact (Money > Security > Data), not by code coverage percentage
  • Effort realism: S = <1h, M = 1-4h, L = >4h
  • Usefulness Score threshold: Only flag E2E tests with Score <15 as wasteful
  • No pyramid enforcement: Do not recommend E2E/Integration/Unit ratios — focus on critical path coverage

Definition of Done

  • contextStore parsed successfully (including output_dir)
  • Critical paths identified (Money, Security, Data) with Priority scores
  • All 3 checks completed (critical path coverage, user journey coverage, E2E usefulness validation)
  • Findings collected with severity, location, effort, recommendation
  • Score calculated using penalty algorithm
  • Report written to {output_dir}/632-e2e-priority.md (atomic single Write call)
  • Summary returned to coordinator

Reference Files

  • Worker report template: shared/templates/audit_worker_report_template.md
  • Audit scoring formula: shared/references/audit_scoring.md
  • Audit output schema: shared/references/audit_output_schema.md

Version: 3.0.0 Last Updated: 2025-12-23

Source

git clone https://github.com/levnikolaevich/claude-code-skills/blob/master/ln-632-test-e2e-priority-auditor/SKILL.mdView on GitHub

Overview

The E2E Critical Coverage Auditor (L3) validates end-to-end coverage for critical paths (Money, Security, Data) and core journeys using a risk-based approach with no pyramid percentages. It operates as a worker in the ln-630 coordinator pipeline, identifying gaps, flagging wasteful tests, and computing a compliance score, then writes a full markdown audit report to the designated output directory.

How This Skill Works

It parses the contextStore provided by the coordinator to extract tech stack, critical paths, and test metadata, then scans the codebase for critical keywords (money-related, login/auth, export) to identify paths. It checks for existing E2E tests for each path and journey, records violations with severity and effort estimates, computes a score (X/10), and renders a report using the shared audit template to {output_dir}/632-e2e-priority.md in a single write operation.

When to Use It

  • When validating E2E coverage for critical paths (Money, Security, Data Export) with Priority ≥20
  • When identifying core journeys (multi-step flows) that require end-to-end tests
  • When you need to flag potentially wasteful E2E tests (Usefulness Score < 15)
  • When preparing a comprehensive audit report for the ln-630 pipeline
  • When integrating risk-based E2E coverage checks into CI/CD or QA workflows

Quick Start

  1. Step 1: Load contextStore from the coordinator and identify critical paths and journeys
  2. Step 2: Scan codebase for keywords (payment, login, export) and verify E2E coverage
  3. Step 3: Render and write the audit report to {output_dir}/632-e2e-priority.md using the template

Best Practices

  • Focus on critical paths and core journeys first (Priority ≥15) to maximize risk reduction
  • Keep the contextStore structure up to date to ensure accurate scanning and reporting
  • Use the defined keywords (payment, refund, login, auth, export) to identify critical paths
  • Validate that the audit report is written in a single operation to the designated path
  • Review the compliance score alongside severity-based findings to prioritize fixes

Example Use Cases

  • A project with Money and Security critical paths lacking E2E tests triggers CRITICAL and HIGH severities, prompting rapid test authoring
  • Core journey like Registration → Email verification → First login shows HIGH severity when missing end-to-end coverage
  • Data Export path lacks an E2E test; audit flags DATA-EXPORT as HIGH and recommends implementing export tests
  • A multi-step product journey (Search → Add to cart → Checkout) is missing a complete E2E test and is flagged as HIGH
  • An existing E2E test has Usefulness Score < 15, flagged as Potentially wasteful E2E and proposed for refactor

Frequently Asked Questions

Add this skill to your agents
Sponsor this space

Reach thousands of developers