test: expand settings coverage

This commit is contained in:
Peter Steinberger
2025-12-24 17:42:14 +01:00
parent 7fafe54e16
commit deec315f6a
15 changed files with 766 additions and 32 deletions

View File

@@ -0,0 +1,29 @@
import Testing
@testable import Clawdis
@Suite(.serialized)
@MainActor
struct AnthropicAuthControlsSmokeTests {
@Test func anthropicAuthControlsBuildsBodyLocal() {
let pkce = AnthropicOAuth.PKCE(verifier: "verifier", challenge: "challenge")
let view = AnthropicAuthControls(
connectionMode: .local,
oauthStatus: .connected(expiresAtMs: 1_700_000_000_000),
pkce: pkce,
code: "code#state",
statusText: "Detected code",
autoDetectClipboard: false,
autoConnectClipboard: false)
_ = view.body
}
@Test func anthropicAuthControlsBuildsBodyRemote() {
let view = AnthropicAuthControls(
connectionMode: .remote,
oauthStatus: .missingFile,
pkce: nil,
code: "",
statusText: nil)
_ = view.body
}
}