Skip to content

test: expose source selector hooks#631

Open
AjTheSpidey wants to merge 1 commit into
siddharthvaddem:mainfrom
AjTheSpidey:codex/source-selector-test-hooks
Open

test: expose source selector hooks#631
AjTheSpidey wants to merge 1 commit into
siddharthvaddem:mainfrom
AjTheSpidey:codex/source-selector-test-hooks

Conversation

@AjTheSpidey
Copy link
Copy Markdown
Contributor

@AjTheSpidey AjTheSpidey commented May 21, 2026

This just wires the source picker UI up to the selectors already used by the Windows smoke test. The HUD source button now has the expected test id, and each source card exposes its test id plus whether it came from a screen or window source. No visual/UI behavior changes intended here.\n\nChecked locally:\n- npx.cmd biome check src/components/launch/LaunchWindow.tsx src/components/launch/SourceSelector.tsx\n- npm.cmd run build-vite\n- npm.cmd run test:e2e -- tests/e2e/windows-native-checklist.spec.ts -g " source selector\

Summary by CodeRabbit

  • Tests
    • Added identifiers to source selector components to improve test coverage and ensure UI stability.

Review Change Stack

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 21, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 27230ef4-4ab1-4ec7-9e88-f0d1ed4fc6d6

📥 Commits

Reviewing files that changed from the base of the PR and between 9f7f498 and ea09fdc.

📒 Files selected for processing (2)
  • src/components/launch/LaunchWindow.tsx
  • src/components/launch/SourceSelector.tsx

📝 Walkthrough

Walkthrough

Added test instrumentation to source selector components. LaunchWindow's source selector button now has a data-testid for test targeting. SourceSelector derives source kind from the source id and exposes both test ID and source kind as data attributes on the card container.

Changes

Test Instrumentation for Source Selector

Layer / File(s) Summary
Test IDs and source kind attributes
src/components/launch/LaunchWindow.tsx, src/components/launch/SourceSelector.tsx
LaunchWindow's source selector button gains data-testid="launch-source-selector-button" for test targeting. SourceSelector's renderSourceCard derives sourceKind from source id (screen vs window) and exposes it via data-source-kind and data-testid="source-selector-card" attributes on the card container.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Suggested reviewers

  • siddharthvaddem

Poem

🎬 test ids flowing free
source kinds now on display
cards and buttons sing
at 2am, we test right
sleepy but complete ✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly describes the main change: adding test identifiers to the source selector UI components for testing purposes.
Description check ✅ Passed The description covers the purpose, motivation, and testing steps, though it doesn't strictly follow all template sections (e.g., Type of Change, Checklist) but provides sufficient detail for understanding the changes.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint skipped: no ESLint configuration detected in root package.json. To enable, add eslint to devDependencies.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

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.

1 participant