Agent skill

RStudio Playwright Test Patterns

by rstudio in rstudio/rstudio

Gotchas and conventions for writing, reviewing and migrating RStudio's TypeScript Playwright tests under e2e/rstudio, beyond what the README covers.

Custom licenceAuto-check passedTesting & QA

Install RStudio Playwright Test Patterns

skills CLI
$ npx skills add rstudio/rstudio --skill rstudio-create-playwright-tests -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install rstudio/rstudio rstudio-create-playwright-tests --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/rstudio/rstudio.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/rstudio-create-playwright-tests .claude/skills/rstudio-create-playwright-tests && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
rstudio-create-playwright-tests
GitHub stars
5.1k
Token cost
~3.9k tokens
SKILL.md length
1,915 words
Files
7
Skills in repo
8
Repo updated
First seen
Licence
Custom licence

At a glance

Gotchas and conventions for writing, reviewing and migrating RStudio's TypeScript Playwright tests under e2e/rstudio, beyond what the README covers.

  • Works in 7 steps: **pressSequentially() for GWT text… → Force-click Ace textareas: await… → Derive selectors from source, never use… → …
  • Writing a new Playwright test for an RStudio pane or dialog
  • SKILL.md covers Before writing, Universal rules, Waits and markers that lie and Server mode and the sandbox, plus 2 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

The test fixture already launches and shuts down RStudio, dismisses save dialogs and cleans buffers, so tests are written as if the IDE starts clean. Before writing, the agent skims existing tests and the pages, actions and utils helpers, and extends `PageObject` for panes or `FramePageObject` for iframe-hosted UI when adding a page object.

The universal rules are RStudio-specific. Use `pressSequentially()` for GWT text inputs whose handlers fire on each keystroke, since `fill()` does not trigger them, and `typeSlowly` at 200ms per character for type-ahead lists. Force-click Ace textareas because an overlay div intercepts normal clicks. Derive selectors from source files such as the command definitions rather than `gwt-uid` values that change each restart. Run commands and preferences through the `window.rstudio` bridge helpers. Separate notes cover authentication, chat, code suggestions, files, terminal and visual editor.

When your agent uses it

  • Writing a new Playwright test for an RStudio pane or dialog
  • Reviewing or migrating tests under e2e/rstudio for flaky selectors
  • Typing into GWT inputs or Ace editors in tests

Example prompts

  • “Write a Playwright test that opens the Files pane and creates a new folder.”
  • “My test types into the Open File dialog but the list never filters, what is wrong?”
  • “Replace the gwt-uid selectors in this test with ones derived from the command IDs.”

Requirements

  • A checkout of the RStudio repository with the e2e/rstudio test setup

Workflow steps

7 steps, taken from the first numbered list in SKILL.md.

  1. **pressSequentially() for GWT text inputs whose handlers fire per
  2. Force-click Ace textareas: await locator.click({ force: true }). An
  3. Derive selectors from source, never use gwt-uid-XXXX (those change
  4. Invoke RStudio commands and prefs via the window.rstudio bridge --
  5. Decision order for triggering an action: GUI button/menu/shortcut, then
  6. RStudio binds some shortcuts to plain Ctrl on every platform
  7. Tests must work on Desktop and Server. Prefer stable IDs over wrapper

What it can do on your machine

Read from SKILL.md and the folder at commit d051070. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

RStudio Playwright Test Patterns loads about 3.9k tokens when it runs. Until then it costs about 44 tokens; SKILL.md has 1,915 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~44
When it runs · the whole SKILL.md, loaded when a task matches
~3.9k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

Its licence (Custom licence) doesn't allow us to republish the file, so here is its outline and opening line. It has 1,915 words (~3,852 tokens).

“Most of what you need is in e2e/rstudio/README.md (basic structure, conventions, selector hierarchy, Ace interactions, cross-platform shortcuts, sandbox, tags, package deps) and in the existing tests under e2e/rstudio/tests/. The fixture (@fixtures/rstudio.fixture) handles RStudio launch/shutdown, save-dialog dismissal, and buffer cleanup --…”

— opening of SKILL.md by rstudio, Custom licence
name
rstudio-create-playwright-tests

Read the full SKILL.md on GitHub

Files

SKILL.md and 6 other files in .claude/skills/rstudio-create-playwright-tests of rstudio/rstudio.

  • SKILL.md
  • auth-credentials.md
  • chat-pane.md
  • code-suggestions.md
  • files-pane.md
  • terminal.md
  • visual-editor.md

Open the folder on GitHubat commit d051070

Compare with similar skills

RStudio Playwright Test Patterns next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

RStudio Playwright Test Patterns compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
RStudio Playwright Test Patterns this skillrstudio/rstudio5.1k—~3.9kAutomated safety check: PassCustom licence
Svelte Testingspences10/sveltest113—~579Automated safety check: PassMIT
Playwright Login Flowsandrewyng/context-hub14k—~715Automated safety check: PassMIT
Ha Frontend Testinghome-assistant/frontend5.7k—~1.7kAutomated safety check: PassApache-2.0
Playwright Page Objectsbartstc/vite-ts-react-template122—~1kAutomated safety check: NotesMIT
Common Tasksidavidov13/agentic-playwright223—~2.5kAutomated safety check: PassMIT

Similar skills

  • Svelte Testing

    spences10/sveltest

    Fix and create Svelte 5 tests with vitest-browser-svelte and Playwright.

    113 GitHub stars~579 tokensUpdated yesterday
    Testing & QAAuto-check passed
  • Playwright Login Flows

    andrewyng/context-hub

    Collects reusable Playwright patterns for logging in during end-to-end tests: password forms, OAuth redirects, saved browser state and TOTP two-factor codes.

    14k GitHub stars~715 tokensUpdated 4 mo ago
    Testing & QAAuto-check passed
  • Ha Frontend Testing

    home-assistant/frontend

    Home Assistant frontend testing and validation workflow. An agent skill from home-assistant/frontend.

    5.7k GitHub stars~1.7k tokensUpdated today
    Testing & QAAuto-check passed
  • Playwright Page Objects

    bartstc/vite-ts-react-template

    A skill your agent uses when creating page objects or refactoring Playwright E2E tests for better maintainability with Page Object Model patterns.

    122 GitHub stars~1k tokensUpdated yesterday
    Testing & QAAuto-check: notes
  • Common Tasks

    idavidov13/agentic-playwright

    Copy-paste AI prompt templates for common Playwright scaffold development tasks — adding page objects, functional/E2E/API tests, Zod schemas, factories, fixtures, and components.

    223 GitHub stars~2.5k tokensUpdated 6 days ago
    Testing & QAAuto-check passed
  • Playwright E2E Testing

    fugazi/test-automation-skills-agents

    Author and maintain versioned Playwright (@playwright/test) TypeScript UI specs for browser user flows.

    247 GitHub stars~3.2k tokensUpdated 4 days ago
    Testing & QAAuto-check passed

More from rstudio/rstudio

All 8 skills in this repo
  • Converts RStudio Python Selenium electron tests into TypeScript Playwright tests, checking each against a live RStudio before counting it as migrated.

    5.1k GitHub stars~3.6k tokensUpdated yesterday
    Auto-check passed
  • Turns the current release's NEWS.md entries into the RStudio Desktop What's New page, picking only what Desktop users care about, then commits and opens a PR.

    5.1k GitHub stars~2k tokensUpdated yesterday
    Auto-check passed
  • Runs RStudio's Playwright end-to-end tests against the desktop app or a server build with the project's npm scripts, asking you which mode to use first.

    5.1k GitHub stars~801 tokensUpdated yesterday
    Auto-check passed
  • Advances RStudio's pinned copilot-language-server dependency to a specified release, then uploads it to S3, verifies the install, and opens a PR.

    5.1k GitHub stars~1.1k tokensUpdated yesterday
    Auto-check passed
  • Bumps the pinned Electron version across the RStudio repository, updating NEWS.md, package.json, the lockfile and the allowScripts entry.

    5.1k GitHub stars~964 tokensUpdated yesterday
    Auto-check passed
  • Bumps the build-time and installed Node.js versions in the RStudio repository, uploads the binaries to S3, verifies the install and opens a PR.

    5.1k GitHub stars~2.7k tokensUpdated yesterday
    Auto-check passed

Categories

Questions about RStudio Playwright Test Patterns

What does RStudio Playwright Test Patterns do?

Gotchas and conventions for writing, reviewing and migrating RStudio's TypeScript Playwright tests under e2e/rstudio, beyond what the README covers. The test fixture already launches and shuts down RStudio, dismisses save dialogs and cleans buffers, so tests are written as if the IDE starts clean. Before writing, the agent skims existing tests and the pages, actions and utils helpers, and extends `PageObject` for panes or `FramePageObject` for iframe-hosted UI when adding a page object.

When should I use RStudio Playwright Test Patterns?

RStudio Playwright Test Patterns fits situations like: writing a new Playwright test for an RStudio pane or dialog; reviewing or migrating tests under e2e/rstudio for flaky selectors; typing into GWT inputs or Ace editors in tests.

How do I install RStudio Playwright Test Patterns in Claude Code?

Run `npx skills add rstudio/rstudio --skill rstudio-create-playwright-tests -a claude-code`. Or copy the skill folder (.claude/skills/rstudio-create-playwright-tests in rstudio/rstudio) into .claude/skills/rstudio-create-playwright-tests in your project. Claude Code loads it when a task matches its description.

How do I install RStudio Playwright Test Patterns in Codex?

Run `npx skills add rstudio/rstudio --skill rstudio-create-playwright-tests -a codex`. Or copy the skill folder (.claude/skills/rstudio-create-playwright-tests in rstudio/rstudio) into .agents/skills/rstudio-create-playwright-tests in your project. Codex loads it when a task matches its description.

Can I use RStudio Playwright Test Patterns in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add rstudio/rstudio --skill rstudio-create-playwright-tests -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/rstudio-create-playwright-tests, .gemini/skills/rstudio-create-playwright-tests, .github/skills/rstudio-create-playwright-tests and .opencode/skills/rstudio-create-playwright-tests in your project.

What does RStudio Playwright Test Patterns need to run?

SKILL.md names no scripts, command-line tools or credentials: RStudio Playwright Test Patterns is instructions for the agent only. Our summary lists: A checkout of the RStudio repository with the e2e/rstudio test setup.

Does RStudio Playwright Test Patterns access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is RStudio Playwright Test Patterns safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does RStudio Playwright Test Patterns use?

RStudio Playwright Test Patterns has a licence file (the repository's licence) that doesn't match a standard licence. Read it on GitHub before reusing the skill.

How many tokens does RStudio Playwright Test Patterns use?

About 3.9k tokens (SKILL.md is roughly 15k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to RStudio Playwright Test Patterns?

Skills that share tags, products or a category with RStudio Playwright Test Patterns: Svelte Testing (spences10/sveltest, 113 stars), Playwright Login Flows (andrewyng/context-hub, 14k stars), Ha Frontend Testing (home-assistant/frontend, 5.7k stars) and Playwright Page Objects (bartstc/vite-ts-react-template, 122 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains RStudio Playwright Test Patterns?

rstudio (a GitHub organization) maintains it in rstudio/rstudio, which has 5,081 GitHub stars. The repository holds 8 skills in this directory. The repository was last updated on October 6, 2026.

Source: rstudio/rstudio on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.