Token导航 LogoToken导航

Agent Skill · 研究检索

phoenix-playwright-tests(Phoenix Playwright tests 搜索)

用于辅助测试设计、自动化测试、用例整理和回归验证。它适合让 Agent 编写单元测试、端到端测试、测试计划或根据失败日志定位问题。使用时需要确认项目测试框架、运行命令和夹具数据,避免为了通过测试而改坏真实逻辑;涉及浏览器或外部服务时,应区分本地模拟、测试环境和生产环境。

phoenix-playwright-tests 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为操作浏览器;许可证信息还不明确,第三方扫描有未通过项,按安装量在研究检索类的 73,675 个 Skill 里排第 39,733。

总安装 1,371周安装 56GitHub Stars 9,472下载 444核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:phoenix-playwright-tests(Phoenix Playwright tests 搜索)
来源仓库:https://github.com/arize-ai/phoenix
仓库路径:skills/phoenix-playwright-tests
安装命令:
npx skills add https://github.com/arize-ai/phoenix --skill phoenix-playwright-tests
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/arize-ai/phoenix --skill phoenix-playwright-tests

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

用于辅助测试设计、自动化测试、用例整理和回归验证。适合让 Agent 编写单元测试、端到端测试或根据失败日志定位问题。使用时需要确认项目测试框架、运行命令和夹具数据,避免改坏真实逻辑。涉及浏览器或外部服务时,应区分本地模拟、测试环境和生产环境。

phoenix-playwright-tests 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

来源仓库内路径:skills/phoenix-playwright-tests

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/arize-ai/phoenix --skill phoenix-playwright-te…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要操作浏览器,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

phoenix-playwright-tests 怎么安装?

在终端执行 npx skills add https://github.com/arize-ai/phoenix --skill phoenix-playwright-tests。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

phoenix-playwright-tests 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

phoenix-playwright-tests 需要什么权限?

权限级别是操作浏览器。该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

phoenix-playwright-tests 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

phoenix-playwright-tests 用的人多吗?

公开数据是累计安装 1,371 次,近一周安装 56 次,下载 444 次,GitHub 9,472 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

phoenix-playwright-tests 安全吗?

第三方扫描有未通过项,风险较高。除非你确认过源码,否则不建议直接安装到常用环境。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 来源仓库有 9,472 星,维护活跃度相对可查。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
phoenix-playwright-tests

Phoenix Playwright tests 搜索 · 本页

1,3719,472操作浏览器未明确未通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Phoenix Playwright Test Writing

Write end-to-end tests for Phoenix using Playwright. Tests live in app/tests/ and follow established patterns.

Timeout Policy

  • Do not pass timeout args in test code under app/tests.
  • Tune timing centrally in app/playwright.config.ts (global timeout, expect.timeout, use.navigationTimeout, and webServer.timeout).

Quick Start

import { expect, test } from "@playwright/test";
import { randomUUID } from "crypto";

test.describe("Feature Name", () => {
  test.beforeEach(async ({ page }) => {
    await page.goto(`/login`);
    await page.getByLabel("Email").fill("admin@localhost");
    await page.getByLabel("Password").fill("admin123");
    await page.getByRole("button", { name: "Log In", exact: true }).click();
    await page.waitForURL("**/projects");
  });

  test("can do something", async ({ page }) => {
    // Test implementation
  });
});

Test Credentials

UserEmailPasswordRole
Adminadmin@localhostadmin123admin
Membermember@localhost.commember123member
Viewerviewer@localhost.comviewer123viewer

Selector Patterns (Priority Order)

  1. Role selectors (most robust): page.getByRole("button", {name: "Save"}); page.getByRole("link", {name: "Datasets"}); page.getByRole("tab", {name: /Evaluators/i}); page.getByRole("menuitem", {name: "Edit"}); page.getByRole("cell", {name: "my-item"}); page.getByRole("heading", {name: "Title"}); page.getByRole("dialog"); page.getByRole("textbox", {name: "Name"}); page.getByRole("combobox", {name: /mapping/i});
  2. Label selectors: page.getByLabel("Email"); page.getByLabel("Dataset Name"); page.getByLabel("Description");
  3. Text selectors: page.getByText("No evaluators added"); page.getByPlaceholder("Search...");
  4. Test IDs (when available): page.getByTestId("modal");
  5. CSS locators (last resort): page.locator('button:has-text("Save")');

Common UI Patterns

Dropdown Menus

// Click button to open dropdown
await page.getByRole("button", { name: "New Dataset" }).click();
// Select menu item
await page.getByRole("menuitem", { name: "New Dataset" }).click();

Nested Menus (Submenus)

// Open menu, hover over submenu trigger, click submenu item
await page.getByRole("button", { name: "Add evaluator" }).click();
await page
  .getByRole("menuitem", { name: "Use LLM evaluator template" })
  .hover();
await page.getByRole("menuitem", { name: /correctness/i }).click();

// IMPORTANT: Always use getByRole("menuitem") for submenu items, not getByText()
// Playwright's auto-waiting handles the submenu appearance timing
// ❌ BAD - flaky in CI:
// await page.getByText("ExactMatch").first().click();
// ✅ GOOD - reliable:
// await page.getByRole("menuitem", { name: /ExactMatch/i }).click();

Dialogs/Modals

// Wait for dialog
await expect(page.getByRole("dialog")).toBeVisible();
// Fill form in dialog
await page.getByLabel("Name").fill("test-name");
// Submit
await page.getByRole("button", { name: "Create" }).click();
// Wait for close
await expect(page.getByRole("dialog")).not.toBeVisible();

Tables with Row Actions

// Find row by cell content
const row = page.getByRole("row").filter({
  has: page.getByRole("cell", { name: "item-name" }),
});
// Click action button in row (usually last button)
await row.getByRole("button").last().click();
// Select action from menu
await page.getByRole("menuitem", { name: "Edit" }).click();

Tabs

await page.getByRole("tab", { name: /Evaluators/i }).click();
await page.waitForURL("**/evaluators");
await expect(page.getByRole("tab", { name: /Evaluators/i })).toHaveAttribute(
  "aria-selected",
  "true",
);

Form Inputs in Sections

// When multiple textboxes exist, scope to section
const systemSection = page.locator('button:has-text("System")');
const systemTextbox = systemSection
  .locator("..")
  .locator("..")
  .getByRole("textbox");
await systemTextbox.fill("content");

Serial Tests (Shared State)

Use test.describe.serial when tests depend on each other:

test.describe.serial("Workflow", () => {
  const itemName = `item-${randomUUID()}`;

  test("step 1: create item", async ({ page }) => {
    // Creates itemName
  });

  test("step 2: edit item", async ({ page }) => {
    // Uses itemName from previous test
  });

  test("step 3: verify edits", async ({ page }) => {
    // Verifies itemName was edited
  });
});

Assertions

// Visibility
await expect(element).toBeVisible();
await expect(element).not.toBeVisible();

// Text content
await expect(element).toHaveText("expected");
await expect(element).toContainText("partial");

// Attributes
await expect(element).toHaveAttribute("aria-selected", "true");

// Input values
await expect(input).toHaveValue("expected value");

// URL
await page.waitForURL("**/datasets/**/examples");

Navigation Patterns

// Direct navigation
await page.goto("/datasets");
await page.waitForURL("**/datasets");

// Click navigation
await page.getByRole("link", { name: "Datasets" }).click();
await page.waitForURL("**/datasets");

// Extract ID from URL
const url = page.url();
const match = url.match(/datasets\/([^/]+)/);
const datasetId = match ? match[1] : "";

// Navigate with query params
await page.goto(`/playground?datasetId=${datasetId}`);

Running Tests

Before running Playwright tests, build the app so E2E runs against the latest frontend changes:

pnpm run build
# Run specific test file
pnpm exec playwright test tests/server-evaluators.spec.ts --project=chromium

# Run with UI mode
pnpm exec playwright test --ui

# Run specific test by name
pnpm exec playwright test -g "can create"

# Debug mode
pnpm exec playwright test --debug

Avoiding Interactive Report Server

By default, Playwright serves an HTML report after tests finish and waits for Ctrl+C, which can cause command timeouts. Use these options to avoid this:

# Use list reporter (no interactive server)
pnpm exec playwright test tests/example.spec.ts --project=chromium --reporter=list

# Use dot reporter for minimal output
pnpm exec playwright test tests/example.spec.ts --project=chromium --reporter=dot

# Set CI mode to disable interactive features
CI=1 pnpm exec playwright test tests/example.spec.ts --project=chromium

Recommended for automation: Always use --reporter=list or CI=1 when running tests programmatically to ensure the command exits cleanly after tests complete.

Phoenix-Specific Pages

PageURL PatternKey Elements
Datasets/datasetsTable, "New Dataset" button
Dataset Detail/datasets/{id}/examplesTabs (Experiments, Examples, Evaluators, Versions)
Dataset Evaluators/datasets/{id}/evaluators"Add evaluator" button, evaluators table
Playground/playgroundPrompts section, Experiment section
Playground + Dataset/playground?datasetId={id}Dataset selector, Evaluators button
Prompts/prompts"New Prompt" button, prompts table
Settings/settings/general"Add User" button, users table

UI Exploration with agent-browser

When selectors are unclear, use agent-browser to explore the Phoenix UI. For detailed agent-browser usage, invoke the /agent-browser skill.

Quick Reference for Phoenix

# Open Phoenix page (dev server runs on port 6006)
agent-browser open "http://localhost:6006/datasets"

# Get interactive snapshot with element refs
agent-browser snapshot -i

# Click using refs from snapshot
agent-browser click @e5

# Fill form fields
agent-browser fill @e2 "test value"

# Get element text
agent-browser get text @e1

Discovering Selectors Workflow

  1. Open the page: agent-browser open "http://localhost:6006/datasets"
  2. Get snapshot: agent-browser snapshot -i
  3. Find element refs in output (e.g., @e1 [button] "New Dataset")
  4. Interact: agent-browser click @e1
  5. Re-snapshot after navigation/DOM changes: agent-browser snapshot -i

Translating to Playwright

agent-browser outputPlaywright selector
@e1 [button] "Save"page.getByRole("button", {name: "Save"})
@e2 [link] "Datasets"page.getByRole("link", {name: "Datasets"})
@e3 [textbox] "Name"page.getByRole("textbox", {name: "Name"})
@e4 [menuitem] "Edit"page.getByRole("menuitem", {name: "Edit"})
@e5 [tab] "Evaluators 0"page.getByRole("tab", {name: /Evaluators/i})

File Naming

  • Feature tests: {feature-name}.spec.ts
  • Access control: {role}-access.spec.ts
  • Rate limiting: {feature}.rate-limit.spec.ts (runs last)

Common Gotchas

  1. Dialog not closing: Wait for a deterministic post-action signal (e.g., dialog hidden + success row visible)
  2. Multiple elements: Use .first(), .last(), or .nth(n)
  3. Dynamic content: Use regex in name: {name: /pattern/i}
  4. Flaky waits: Prefer waitForURL over waitForTimeout
  5. Menu not appearing: Wait for specific menu state/element visibility

Debugging Flaky Tests

Critical Lessons Learned

  1. Don't assume parallelism is the problem

- Phoenix tests run with 7 parallel workers without issues - The app handles concurrent logins, database operations, and session management properly - If tests fail with parallelism, it's usually a test timing issue, not infrastructure - Playwright's browser context isolation is robust - each worker gets isolated cookies/sessions

  1. waitForTimeout is almost always wrong

- page.waitForTimeout() is the #1 cause of flakiness in Phoenix tests - Arbitrary timeouts race against rendering and network speed - Always replace with state-based waits: // ❌ BAD - flaky, races against rendering await page.waitForTimeout(500); await element.click(); // ✅ GOOD - waits for actual state await element.waitFor({state: "visible"}); await element.click();

  1. Test the actual failure before fixing

- Run tests with parallelism enabled to see what actually fails - Check error messages - they often point to the real issue - Don't optimize prematurely (e.g., caching auth state) if it's not the problem

  1. Phoenix test infrastructure is solid

- In-memory SQLite works fine with parallel tests - No need for per-worker databases - No need for auth state caching - Tests use randomUUID() for data isolation - this works well

Debugging Workflow

When tests are flaky:

  1. Run with parallelism multiple times to catch intermittent failures: for i in 1 2 3 4 5; do pnpm exec playwright test --project=chromium --reporter=dot done
  2. Look for waitForTimeout usage - replace with proper waits: grep -r "waitForTimeout" app/tests/
  3. Check for race conditions in element interactions:

- Wait for element visibility before interacting - Wait for network idle when needed: page.waitForLoadState("networkidle") - Use waitForURL after navigation actions

  1. Verify selectors are stable:

- Avoid CSS selectors that depend on DOM structure - Use role/label selectors that match ARIA attributes - Test selectors don't break when UI updates

  1. Run with trace on failure to see what happened: pnpm exec playwright test --trace on-first-retry

Common Flaky Patterns and Fixes

Flaky PatternRoot CauseFix
Submenu item not foundUsing getByText() instead of getByRole()Use getByRole("menuitem", {name: /pattern/i}) for submenu items
Menu click failsMenu not fully renderedawait menu.waitFor({state: "visible"}) before click
Dialog assertion failsDialog animation not completeAssert specific completion signal (hidden dialog + next-state element)
Navigation timeoutPage still loadingRemove waitForLoadState("networkidle") - it's flaky in CI
Element not foundDynamic content loadingWait for element visibility, not arbitrary timeout
Stale elementRe-render between locate and clickStore locator, not element handle

Test Stability Best Practices

  1. Use proper waits: // Wait for element state await element.waitFor({state: "visible" | "hidden" | "attached"}) // Wait for network await page.waitForLoadState("networkidle" | "domcontentloaded" | "load") // Wait for URL change await page.waitForURL("**/expected-path")
  2. Use unique test data: ` const uniqueName = test-${randomUUID()}; `
  3. Prefer role selectors - they're less brittle: page.getByRole("button", {name: "Save"}) // ✅ Good page.locator('button.save-btn') // ❌ Brittle
  4. Don't fight animations - wait for them: await expect(dialog).not.toBeVisible();
  5. Verify URL changes after navigation: await page.waitForURL("**/datasets");

平台分布

Codex

37.74%
按下载量换算168

Claude

27.51%
按下载量换算122

Cursor

20.39%
按下载量换算91

Gemini CLI

9.59%
按下载量换算43

安全审计

Gen Agent Trust Hub

可疑

Socket

通过

Snyk

未通过

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills