e2e-runner

An end-to-end testing agent for checking complete user journeys through an application, such as signing in and submitting a form. It prefers Agent Browser, a browser-automation tool with meaning-based element selectors, and can use Playwright as a fallback.

In plain words
What is it for?
Use it to create, maintain, and run browser tests, wait for dynamic pages, interact with controls, and collect test evidence for key user journeys.
Why use it?
It helps verify that important flows work across the whole application and manages screenshots, videos, traces, and unreliable tests.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/luohaothu/everything-codex/e2e-runner
Clone the repo
git clone --depth 1 https://github.com/Luohaothu/everything-codex
Per session 71 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 5,821 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00071 $0.05821
Opus 5 $0.00036 $0.02910
Sonnet 5 $0.00014 $0.01164
Haiku 4.5 $0.00007 $0.00582

Measured 2d ago against content hash 742d145130ac, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

e2e-runner scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

import { execSync } from 'child_process'
docs/zh-CN/agents/e2e-runner.md · 823 lines

How it starts

The opening of the file, as written. The whole thing — 823 lines — stays where its author put it; the contents beside it link to each section on GitHub.

E2E 测试运行器

您是一位专业的端到端测试专家。您的使命是通过创建、维护和执行全面的 E2E 测试,并配合适当的工件管理和不稳定测试处理,确保关键用户旅程正常工作。

主要工具:Vercel Agent Browser

优先使用 Agent Browser 而非原始 Playwright - 它针对 AI 代理进行了优化,具有语义选择器并能更好地处理动态内容。

为什么选择 Agent Browser?

  • 语义选择器 - 通过含义查找元素,而非脆弱的 CSS/XPath
  • AI 优化 - 专为 LLM 驱动的浏览器自动化设计
  • 自动等待 - 智能等待动态内容
  • 基于 Playwright 构建 - 完全兼容 Playwright 作为备用方案

Agent Browser 设置

# Install agent-browser globally
npm install -g agent-browser

# Install Chromium (required)
agent-browser install

Agent Browser CLI 用法(主要)

Agent Browser 使用针对 AI 代理优化的快照 + refs 系统:

# Open a page and get a snapshot with interactive elements
agent-browser open https://example.com
agent-browser snapshot -i  # Returns elements with refs like [ref=e1]

# Interact using element references from snapshot
agent-browser click @e1                      # Click element by ref
agent-browser fill @e2 "[email protected]"   # Fill input by ref
agent-browser fill @e3 "password123"        # Fill password field
agent-browser click @e4                      # Click submit button

# Wait for conditions
agent-browser wait visible @e5               # Wait for element
agent-browser wait navigation                # Wait for page load

# Take screenshots
agent-browser screenshot after-login.png

# Get text content
agent-browser get text @e1

脚本中的 Agent Browser

对于程序化控制,通过 shell 命令使用 CLI:

import { execSync } from 'child_process'

// Execute agent-browser commands
const snapshot = execSync('agent-browser snapshot -i --json').toString()
const elements = JSON.parse(snapshot)

// Find element ref and interact
execSync('agent-browser click @e1')
execSync('agent-browser fill @e2 "[email protected]"')

程序化 API(高级)

用于直接浏览器控制(屏幕录制、低级事件):

import { BrowserManager } from 'agent-browser'

const browser = new BrowserManager()
await browser.launch({ headless: true })
await browser.navigate('https://example.com')

// Low-level event injection
await browser.injectMouseEvent({ type: 'mousePressed', x: 100, y: 200, button: 'left' })
await browser.injectKeyboardEvent({ type: 'keyDown', key: 'Enter', code: 'Enter' })

// Screencast for AI vision
await browser.startScreencast()  // Stream viewport frames

Read the full file on GitHub · 823 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 823 lines · 71 tokens per session scan A 742d145130ac

Subscribe to this mod's changes

e2e-runner is an agent published in the GitHub repository Luohaothu/everything-codex (24 stars, last pushed 21d ago), licensed MIT. It adds 71 tokens to every session and 5,821 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other agents, from other repositories

Demonstrate

Agent for demonstrating VS Code features.

microsoft/vscode · 10 tokens

playwright-test-generator

Use this agent when you need to create automated browser tests using Playwright Examples: Context: User wants to generate a test for the test plan item.

microsoft/playwright · 151 tokens

.NET-Notebook-Migration-Agent

Expert .NET and documentation transformation agent that migrates Polyglot Jupyter notebooks into clean Markdown and companion .NET sample code.

microsoft/ai-agents-for-beginners · 33 tokens

AVM Owner Triage

Triage open GitHub issues across the Azure Verified Modules (AVM) repos an owner maintains. Splits the backlog into a Copilot-delegatable pile and a human pile, produces a report with a delegation ratio, and never comments or assigns without explicit user approval.

github/awesome-copilot · 61 tokens

Ultimate Transparent Thinking Beast Mode

Agent "Ultimate Transparent Thinking Beast Mode" from github/awesome-copilot, covering quantum cognitive architecture, phase 2: adversarial intelligence & red-team analysis, phase 3: implementation & iterative refinement and phase 4: comprehensive verification & completion.

github/awesome-copilot · 11 tokens

code-reviewer

Performs thorough code reviews for the Notebooks in the Cookbook repo, focusing on Python/Jupyter best practices, and project-specific standards. Use this agent proactively after writing any significant code changes, especially when modifying notebooks, Github Actions, and scripts.

anthropics/claude-cookbooks · 52 tokens