assessing-external-test-risk

Assesses PR diffs for external hosting risks and recommends external e2e test coverage.

45.7k|4.4k|Updated Aug 24, 2019
One-click install
npx skills add https://github.com/streamlit/streamlit --skill assessing-external-test-risk
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: assessing-external-test-risk
Source: https://github.com/streamlit/streamlit/tree/main/.claude/skills/assessing-external-test-risk
Command: npx skills add https://github.com/streamlit/streamlit --skill assessing-external-test-risk

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Changes to Streamlit's routing, auth, websocket, embedding, or asset-serving code can break externally hosted or embedded deployments (proxies, iframes, CSP constraints) even when local tests pass. This Skill reviews a branch or PR diff and decides whether external end-to-end coverage with @pytest.mark.external_test is warranted.

Core Features & Use Cases

  • Eleven-category risk checklist: Evaluates routing, auth/cookies/CSRF, websocket transport, iframe embedding, static assets, service workers, cross-origin behavior, SiS/Snowflake runtime, client storage, and security headers.
  • Any-hit decision rule: A single triggered category produces a "Recommend external_test: Yes" verdict with concrete diff evidence.
  • Structured output: Produces a standardized recommendation with triggered categories, file-level evidence, suggested test focus areas, confidence level, and assumptions.
  • Use Case: During PR triage, a reviewer runs this assessment on a diff touching Starlette routes and XSRF cookie handling, and receives a Yes recommendation with focus areas for iframe embedding and auth/session continuity checks.

Quick Start

Review this pull request diff and tell me whether it needs external e2e test coverage with @pytest.mark.external_test.

Frequently Asked Questions about assessing-external-test-risk

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I decide if a Streamlit PR needs external e2e tests?

Review the PR diff against an eleven-category checklist covering routing, auth, websockets, embedding, assets, cross-origin behavior, SiS runtime, storage, and security headers. If any category is hit, recommend external_test coverage with concrete focus areas.

What is @pytest.mark.external_test used for in Streamlit?

It marks end-to-end tests that validate behavior in externally hosted or embedded deployments, where proxies, iframes, CSP constraints, and browser security boundaries can diverge from local runs. The skill recommends when such coverage is needed but does not auto-mark tests.

Which code changes trigger an external test recommendation?

Changes to Starlette routes, cookie/XSRF handling, websocket handshakes, iframe postMessage or sandbox attributes, asset cache headers, service workers, CORS allowlists, SiS/Snowflake runtime calls, client storage, or CSP and related security headers.

Does this skill automatically add external_test markers to tests?

No. It performs risk assessment and recommendation only, outputting a verdict, triggered categories, evidence, and suggested focus areas. It marks tests only when explicitly requested by the user.

What inputs are required to run an external test risk assessment?

The assessment needs the branch or PR diff against its base branch, the list of changed files and related tests, and optionally the PR description. Each recommendation must cite concrete evidence from file paths and diff snippets.