Skip to content

👷 playground improvements: RUM Explorer button and Playwright test infra#98

Merged
bcaudan merged 9 commits into
mainfrom
bcaudan/playground-improvements
Jun 16, 2026
Merged

👷 playground improvements: RUM Explorer button and Playwright test infra#98
bcaudan merged 9 commits into
mainfrom
bcaudan/playground-improvements

Conversation

@bcaudan

@bcaudan bcaudan commented Apr 17, 2026

Copy link
Copy Markdown
Collaborator

Motivation

The playground lacked tooling for quick session debugging and had no automated test coverage beyond a fragile sleep-based launch check. This PR adds developer-facing features and a proper test infrastructure that agents can use to prototype and self-validate.

Changes

  • Add getInternalContext() internal SDK API exposing session_id for tooling
  • Add "Open in RUM Explorer" button that opens a pre-filtered RUM session in the browser
  • Add Playwright test infrastructure with mock intake, headless mode (DD_TEST_MODE), and proxy override (DD_SDK_PROXY)
  • Replace the sleep-based CI runtime check with yarn test running Playwright scenarios
  • Consolidate playground documentation into playground/README.md

Test instructions

# Unit tests (includes new getInternalContext tests)
yarn test

# Playground Playwright test
cd playground && yarn test

# Manual: launch playground, click "Open in RUM Explorer"
yarn dev:playground

Checklist

  • Tested locally (playground)
  • Added unit tests for this change.
  • Added e2e/integration tests for this change.
  • Updated related documentation.

bcaudan added 2 commits April 17, 2026 14:49
Exposes session_id for tooling (e.g. linking to RUM Explorer).
Returns undefined when SDK is not initialized or session is expired.
Uses getInternalContext() to build a pre-filtered RUM Explorer URL
and opens it in the default browser via shell.openExternal().
@bcaudan bcaudan force-pushed the bcaudan/playground-improvements branch from 6300f73 to 7425ac2 Compare April 17, 2026 13:54
- Test mode support: DD_TEST_MODE (headless), DD_SDK_PROXY (mock intake)
- Playwright fixtures reusing e2e/lib/intake.ts
- Replace scripts/cli runtime check with direct yarn test in CI
- Move playground docs from DEVELOPMENT.md to playground/README.md
@bcaudan bcaudan force-pushed the bcaudan/playground-improvements branch from 7425ac2 to c64311b Compare April 17, 2026 13:57
@bcaudan bcaudan marked this pull request as ready for review April 17, 2026 15:23
@bcaudan bcaudan requested a review from a team as a code owner April 17, 2026 15:23
@bcaudan bcaudan requested a review from cdn34dd May 5, 2026 07:57
@cdn34dd

cdn34dd commented Jun 15, 2026

Copy link
Copy Markdown
Collaborator

Nice quality of life changes, looks good, I can double check it again if needed once we rebase on develop.

cdn34dd
cdn34dd previously approved these changes Jun 15, 2026
@datadog-official

This comment has been minimized.

@bcaudan

bcaudan commented Jun 16, 2026

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f6c7266238

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread playground/test/helpers.ts Outdated
@bcaudan bcaudan requested a review from cdn34dd June 16, 2026 08:33
@bcaudan bcaudan merged commit 88e2c76 into main Jun 16, 2026
15 checks passed
@bcaudan bcaudan deleted the bcaudan/playground-improvements branch June 16, 2026 08:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants