Repository navigation
test(frontend): assert status icons in TestResultBadge and AiProviderSettings - #1440
Merged
smart-ssh-coordinator[bot] merged 1 commit intoNov 21, 2026
Conversation
…Settings (#1401) Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
4 tasks
4 tasks
There was a problem hiding this comment.
Review
Verdict: approved
Review level: normal
Blocking
- None.
Non-blocking
- None.
Verified
- AC 1:
TestResultBadge.test.tsx:renders the check icon for the success state(kind: "success"→data-icon="check") and:renders the x icon for the failure state(kind: "authenticationFailed"→data-icon="x"). Both matchserverForm/TestResultBadge.tsx. (read) - AC 2:
AiProviderSettings.test.tsx:shows a valid result→check,:shows an authentication-failed result→x. The assertion is scoped to the<p>returned byfindByText, which inAddAiProviderDialog.tsxrenders theIconand the text together. (read) - AC 3 / counter-proof: I removed the success icon from
TestResultBadge(no icon), swapped the auth-failed icon towarn(different icon), and swapped the credentials-test icons towarn/checkinAddAiProviderDialog. All 4 new or extended assertions failed. After restoring the files they passed again andgit statuswas clean. (executed:npx vitest run src/components/TestResultBadge.test.tsx src/components/AiProviderSettings.test.tsx) - tests run locally: same command → 77 passed (executed);
npx tsc -b→ clean (executed) - CI: all checks green (executed:
gh pr checks 1440) - edge cases: no icon → test fails (checked); wrong icon → test fails (checked); the first
svgin the badge container is the status icon, since the badge renders only that one icon (read) - callers checked: test-only change, no production code touched
- files read: 2/2 logic files
- UI: not a UI change (test-only)
- data: not touched
- neighbouring work: open PR #1425 also appends tests at the end of
TestResultBadge.test.tsx. It also replaces the badge's inlineIconwith aBadge. Whichever PR merges second has to reconcile this: either a merge conflict or the new icon assertions. CI on that PR will catch it. This is not a defect of this PR.
Timing analysis
- 2 test files analysed: no timing dependency found. The badge tests are synchronous renders. In the AI provider tests, the icon and the text appear in the same render after
findByText.
Spec
- visible behaviour changed: none (test-only)
- spec searched (
rg -il 'Verbindungstest|Zugangsdaten testen|test connection' docs/specs/): the area is covered by 0069 and 0050/0056. No change needed. - verdict: not needed, because the PR only adds test assertions
Security checks
- No production code, filter, redaction, credential or execution path is touched. Threat model note "no change – tests only" is fine. PR title, body and commit are in English and contain no internals.
Follow-ups
- None.
smart-ssh-coordinator
Bot
deleted the
issue-1401-tests-assert-the-status-icon-in
branch
November 21, 2026 10:25
This was referenced Nov 21, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1401
Summary
Test-only: asserts the rendered
Icon(data-icon) for the connection-test badge and the AI provider credentials-test result.Acceptance Criteria
TestResultBadge.test.tsxasserts icon for success and failure: met (renders the check icon for the success state,renders the x icon for the failure state)AiProviderSettings.test.tsxasserts icon for its test result: met (shows a valid result→ check,shows an authentication-failed result→ x)Tests
Counter-proof: swapping the icon names in the components made 3 of the new/extended tests fail; restored afterwards.
Assumptions
None.
Spec: none (test-only)
Threat model: no change – tests only
Manual test steps: none
Follow-ups: None.
🤖 Generated with Claude Code