mirror of
https://github.com/stablyai/orca.git
synced 2026-10-22 00:03:47 +00:00
Merge remote-tracking branch 'origin/main' into brennanb2025/retire-generated-workspace-names
This commit is contained in:
@@ -244,8 +244,12 @@ jobs:
|
||||
if printf '%s\n' "${TEST_FILES[@]}" | grep -qx 'tests/e2e/ephemeral-vm-provisioned-root.spec.ts'; then
|
||||
E2E_ENV+=(ORCA_E2E_SSH_DOCKER=1)
|
||||
fi
|
||||
E2E_PROJECT_ARGS=()
|
||||
if grep -l '@headful' "${TEST_FILES[@]}" >/dev/null; then
|
||||
E2E_PROJECT_ARGS+=(--project=electron-headful)
|
||||
fi
|
||||
xvfb-run --auto-servernum env "${E2E_ENV[@]}" \
|
||||
pnpm run test:e2e "${TEST_FILES[@]}" --workers=1
|
||||
pnpm run test:e2e "${TEST_FILES[@]}" --workers=1 "${E2E_PROJECT_ARGS[@]}"
|
||||
|
||||
- name: Upload Playwright traces
|
||||
if: failure()
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"schemaVersion": 1,
|
||||
"updatedAt": "2026-08-12",
|
||||
"updatedAt": "2026-08-13",
|
||||
"policy": {
|
||||
"maturityLevels": ["experimental", "soak", "blocking", "accepted-gap", "deprecated"],
|
||||
"blockingPromotion": {
|
||||
@@ -1817,19 +1817,24 @@
|
||||
"providers": ["remote-runtime"],
|
||||
"coveredPlatforms": ["macos"],
|
||||
"coveredProviders": ["remote-runtime"],
|
||||
"coverageNotes": "A headed macOS desktop host and separate paired client exercise the Explorer eye-button path with a real remote file URL, host browser DOM, renderer split layout, background preview creation, explicit browser activation, browser close, forced capability rejection after caller preflight, and a forced post-create reconciliation timeout. The same fault oracles pass against a live headless server. Unit contracts cover absent, unknown, and mixed-version capabilities, visible rejection, empty-split cleanup, owning-runtime routing, exact client materialization, confirmed rollback, ambiguous cleanup, and teardown. Linux and Windows live journeys remain gaps.",
|
||||
"coverageNotes": "A headed macOS desktop host and separate paired client exercise the Explorer eye-button path with a real remote file URL, host browser DOM, renderer split layout, background preview creation, explicit browser activation, browser close, forced capability rejection after caller preflight, a forced post-create reconciliation timeout, and navigation held beyond the client create deadline. The same reconciliation fault oracles pass against a live headless server. Unit contracts cover absent, unknown, and mixed-version capabilities, visible rejection, empty-split cleanup, owning-runtime routing, canonical preallocated page identity, navigation-independent acknowledgement, exact client materialization, confirmed rollback, ambiguous cleanup, and teardown. Linux and Windows live journeys remain gaps.",
|
||||
"motivatingLinks": [
|
||||
"https://linear.app/stably/issue/STA-3872/unable-to-open-html-files-in-remote-server",
|
||||
"https://linear.app/stably/issue/STA-4025/p1-browser-create-reports-success-when-tab-reconcile-fails-after-pr",
|
||||
"https://linear.app/stably/issue/STA-4063/p1-paired-html-preview-rejects-outside-cleanup-after-pr-13909",
|
||||
"https://linear.app/stably/issue/STA-4231/p1-owner-pinned-paired-browser-create-can-time-out-after-host-tab",
|
||||
"https://github.com/stablyai/orca/pull/14363",
|
||||
"https://github.com/stablyai/orca/pull/13876"
|
||||
],
|
||||
"invariant": "Opening one HTML preview from a paired client succeeds only after exactly one browser page on the worktree-owning runtime materializes as exactly one client browser workspace and unified tab in the requested group. Capability rejection before host mutation must preserve the original error, issue no RPC, surface a failure toast, and remove only a caller-declared newly-created empty split. Post-create reconciliation failure requires exact rollback; ambiguous rollback rejects without local fallback. Preview focus and close preserve the source editor and terminal.",
|
||||
"oracle": "Run one unchanged contract oracle for direct create and side-preview callers with absent status, unknown capabilities, and a mixed-version host. Require the original unsupported error or visible toast, zero RPCs, and no retained new split. Run it on the scan target, latest main, candidate, and candidate with the cleanup boundary disabled. In headed paired Electron, arm capability rejection after the caller preflight, invoke the visible HTML side-preview action, require the failure toast, and compare exact host/client browser, editor, terminal, and group inventories to baseline. Repeat against headless serve. Retain the separate exact-page reconciliation rollback oracle.",
|
||||
"invariant": "Opening one HTML preview from a paired client succeeds only after exactly one browser page on the worktree-owning runtime materializes as exactly one client browser workspace and unified tab in the requested group. Owner-pinned creation returns the canonical host page identity before navigation readiness; delayed navigation cannot turn a created page into an unidentifiable failure or a duplicate retry. Capability rejection before host mutation must preserve the original error, issue no RPC, surface a failure toast, and remove only a caller-declared newly-created empty split. Post-create reconciliation failure requires exact rollback; ambiguous rollback rejects without local fallback. Preview focus and close preserve the source editor and terminal.",
|
||||
"oracle": "Run one unchanged contract oracle for direct create and side-preview callers with absent status, unknown capabilities, and a mixed-version host. Require the original unsupported error or visible toast, zero RPCs, and no retained new split. Run it on the scan target, latest main, candidate, and candidate with the cleanup boundary disabled. In headed paired Electron, arm capability rejection after the caller preflight, invoke the visible HTML side-preview action, require the failure toast, and compare exact host/client browser, editor, terminal, and group inventories to baseline. Hold a real navigation response beyond the 15-second client deadline after host creation; require the first RPC to return the exact host inventory page ID, one host page, and no retry. Repeat reconciliation faults against headless serve. Retain the separate exact-page reconciliation rollback oracle.",
|
||||
"commands": [
|
||||
"pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/orca-runtime-browser.test.ts src/main/runtime/rpc/methods/browser.test.ts src/renderer/src/lib/file-preview.test.ts src/renderer/src/runtime/web-session-browser-placement.test.ts src/renderer/src/runtime/web-runtime-session.test.ts src/renderer/src/runtime/web-session-tabs-sync.test.ts src/renderer/src/runtime/remote-server-parity.test.ts",
|
||||
"pnpm exec vitest run --config config/vitest.config.ts src/renderer/src/runtime/web-runtime-browser-materialization.test.ts",
|
||||
"pnpm exec vitest run --config config/vitest.config.ts src/renderer/src/runtime/web-runtime-browser-capability-cleanup.test.ts src/renderer/src/lib/file-preview-capability-cleanup.test.ts",
|
||||
"pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/orca-runtime-browser.test.ts src/renderer/src/runtime/web-runtime-session.test.ts",
|
||||
"pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/orca-runtime.test.ts src/main/runtime/orca-runtime-browser.test.ts src/renderer/src/hooks/useIpcEvents.test.ts src/renderer/src/store/slices/browser.test.ts src/renderer/src/runtime/web-runtime-session.test.ts",
|
||||
"SKIP_BUILD=1 pnpm exec playwright test tests/e2e/paired-browser-create-navigation-deadline.spec.ts --config tests/playwright.config.ts --project electron-headful --workers=1",
|
||||
"ORCA_E2E_WEB_CLIENT=1 ORCA_E2E_FORCE_HEADFUL=1 ORCA_E2E_FORWARD_APP_LOGS=1 pnpm exec playwright test tests/e2e/paired-remote-html-browser-focus.spec.ts --config tests/playwright.config.ts --project electron-headless --workers=1",
|
||||
"ORCA_E2E_WEB_CLIENT=1 ORCA_E2E_FORCE_HEADFUL=1 ORCA_E2E_FORWARD_APP_LOGS=1 pnpm exec playwright test tests/e2e/paired-remote-html-browser-focus.spec.ts --config tests/playwright.config.ts --project electron-headless --workers=1 --repeat-each=3",
|
||||
"SKIP_BUILD=1 ORCA_E2E_WEB_CLIENT=1 ORCA_E2E_FORCE_HEADFUL=1 pnpm exec playwright test tests/e2e/paired-remote-html-browser-focus.spec.ts --config tests/playwright.config.ts --project electron-headless --workers=1",
|
||||
@@ -1848,7 +1853,10 @@
|
||||
"src/renderer/src/runtime/web-runtime-session.test.ts",
|
||||
"src/renderer/src/runtime/web-session-tabs-sync.test.ts",
|
||||
"src/renderer/src/runtime/remote-server-parity.test.ts",
|
||||
"src/renderer/src/hooks/useIpcEvents.test.ts",
|
||||
"src/renderer/src/store/slices/browser.test.ts",
|
||||
"tests/e2e/paired-remote-html-browser-focus.spec.ts",
|
||||
"tests/e2e/paired-browser-create-navigation-deadline.spec.ts",
|
||||
"tests/e2e/paired-browser-creation-reconciliation-failure.spec.ts"
|
||||
],
|
||||
"assertionRefs": [
|
||||
@@ -1884,12 +1892,36 @@
|
||||
"file": "src/renderer/src/runtime/web-runtime-session.test.ts",
|
||||
"assertions": [
|
||||
"a post-create timeout returns false only after exact host close and a confirming snapshot",
|
||||
"owner-pinned creation launches navigation separately and materializes without awaiting it",
|
||||
"a lost create acknowledgement cleans the capability-gated canonical page ID",
|
||||
"unconfirmed cleanup rejects so callers cannot create a competing local fallback",
|
||||
"the canonical placement and a newly-created empty split are released on rollback",
|
||||
"one failed preview cannot remove a shared split still reserved after an environment ownership change",
|
||||
"if every overlapping creation fails, the last reservation closes the caller-created empty split"
|
||||
]
|
||||
},
|
||||
{
|
||||
"file": "src/main/runtime/orca-runtime-browser.test.ts",
|
||||
"assertions": [
|
||||
"explicit renderer cleanup bypasses guest registration while retaining typed missing-page behavior",
|
||||
"offscreen cleanup rejects a page outside the requested worktree"
|
||||
]
|
||||
},
|
||||
{
|
||||
"file": "src/renderer/src/hooks/useIpcEvents.test.ts",
|
||||
"assertions": [
|
||||
"renderer-backed creation preserves the requested canonical page ID while keeping its workspace identity independent",
|
||||
"closing an absent renderer page returns browser_tab_not_found instead of an untyped failure",
|
||||
"explicit cleanup cannot close a page owned by another worktree"
|
||||
]
|
||||
},
|
||||
{
|
||||
"file": "src/renderer/src/store/slices/browser.test.ts",
|
||||
"assertions": [
|
||||
"a requested canonical page ID is stored on the page rather than reused as its workspace ID",
|
||||
"duplicate canonical page IDs are rejected before a second tab can materialize"
|
||||
]
|
||||
},
|
||||
{
|
||||
"file": "src/renderer/src/runtime/web-session-browser-placement.test.ts",
|
||||
"assertions": [
|
||||
@@ -1921,6 +1953,13 @@
|
||||
"preview creation leaves the editor active, an explicit browser click is authoritative, and close preserves the editor and terminal"
|
||||
]
|
||||
},
|
||||
{
|
||||
"file": "tests/e2e/paired-browser-create-navigation-deadline.spec.ts",
|
||||
"assertions": [
|
||||
"a held navigation exceeds the former create deadline while the first RPC returns the exact authoritative host page ID",
|
||||
"host inventory contains exactly one new page and the user retry branch is never entered"
|
||||
]
|
||||
},
|
||||
{
|
||||
"file": "tests/e2e/paired-browser-creation-reconciliation-failure.spec.ts",
|
||||
"assertions": [
|
||||
@@ -2075,6 +2114,24 @@
|
||||
"result": "failed",
|
||||
"durationSeconds": 12.3,
|
||||
"summary": "Candidate d05217c40d with only the side-preview focusOnCreate:false call disabled failed the byte-identical 2ec1dcf1 oracle because preview creation activated the browser instead of preserving editor focus."
|
||||
},
|
||||
{
|
||||
"date": "2026-08-13",
|
||||
"runner": "local",
|
||||
"platform": "macos",
|
||||
"command": "pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/orca-runtime.test.ts src/main/runtime/orca-runtime-browser.test.ts src/renderer/src/hooks/useIpcEvents.test.ts src/renderer/src/store/slices/browser.test.ts src/renderer/src/runtime/web-runtime-session.test.ts",
|
||||
"result": "passed",
|
||||
"durationSeconds": 10.83,
|
||||
"summary": "Five post-review host, IPC, store, and client lifecycle files passed 1,356 tests with one pre-existing skip, including both shards that failed before the canonical page/workspace identity and typed missing-page cleanup corrections."
|
||||
},
|
||||
{
|
||||
"date": "2026-08-13",
|
||||
"runner": "local",
|
||||
"platform": "macos",
|
||||
"command": "SKIP_BUILD=1 pnpm exec playwright test tests/e2e/paired-browser-create-navigation-deadline.spec.ts --config tests/playwright.config.ts --project electron-headful --workers=1",
|
||||
"result": "passed",
|
||||
"durationSeconds": 18.1,
|
||||
"summary": "Two isolated headed Electron/CDP journeys passed: the direct owner-pinned call returned one canonical host ID before held navigation, and the real remote-pane context-menu route materialized that one page without retry or duplicate."
|
||||
}
|
||||
],
|
||||
"runtimeBudget": {
|
||||
@@ -2087,11 +2144,11 @@
|
||||
},
|
||||
"redGreenEvidence": {
|
||||
"status": "complete",
|
||||
"evidence": "The unchanged STA-4063 five-assertion oracle is red 5/5 on scan e4c278eb52 and latest main bc2e30000b, partially green 2/5 on pre-fix PR #14100, green 5/5 on candidate 14b5877a75, and red 3/5 when only the new transaction cleanup boundary is disabled on final candidate a9e6fb7716. The earlier STA-4025 transaction oracle remains red on the post-#13909 base and green on this candidate. The byte-identical 2ec1dcf1 Electron oracle remains red on latest main 346e59c879, green on candidate d05217c40d, and red with only side-preview focus disabled; historical 5806b23f evidence separately proves owning-runtime routing."
|
||||
"evidence": "The unchanged STA-4063 five-assertion oracle is red 5/5 on scan e4c278eb52 and latest main bc2e30000b, partially green 2/5 on pre-fix PR #14100, green 5/5 on candidate 14b5877a75, and red 3/5 when only the new transaction cleanup boundary is disabled on final candidate a9e6fb7716. The earlier STA-4025 transaction oracle remains red on the post-#13909 base and green on this candidate. The byte-identical STA-4231 headed oracle is red on latest-main b19d99bd00: both 15-second creates return runtime_timeout without a page ID while the host retains two distinct pages after retry. The relevant behavior is unchanged through 0a0ae974d4. The candidate is green with one returned canonical ID, one host/client page, and no retry; disabling only the navigation-independent acknowledgement is red with the same two orphaned pages. The byte-identical 2ec1dcf1 Electron oracle remains red on latest main 346e59c879, green on candidate d05217c40d, and red with only side-preview focus disabled; historical 5806b23f evidence separately proves owning-runtime routing."
|
||||
},
|
||||
"performanceBudget": {
|
||||
"required": true,
|
||||
"evidence": "The transaction adds no timer, polling, retry, subprocess, RPC method, stream opcode, or host publication. Capability rejection performs zero RPCs and one bounded empty-group close. Successful creation adds one post-operation list; known-page failure adds one exact close and one confirming list. The E2E-only one-shot faults are build-gated, retain one promise/flag and a bounded page-id set, and reset after each run. Pending client placements remain capped at 128 and clear on adoption, failure, or teardown."
|
||||
"evidence": "The transaction adds no timer, polling, retry, subprocess, RPC method, stream opcode, or global host publication. Owner-pinned success performs one create RPC followed by one asynchronous goto, retains one page, and performs zero retry or cleanup calls. A lost create acknowledgement performs one exact close by the preallocated canonical ID and at most one confirming snapshot. Headless goto publishes one worktree-scoped session snapshot after navigation. Capability rejection performs zero RPCs and one bounded empty-group close. The E2E-only one-shot faults are build-gated, retain one promise/flag and a bounded page-id set, and reset after each run. Pending client placements remain capped at 128 and clear on adoption, failure, or teardown."
|
||||
},
|
||||
"promotionCriteria": [
|
||||
"Collect Linux and physical Windows paired-server evidence.",
|
||||
|
||||
@@ -75,7 +75,11 @@ describe('PR E2E gate contract', () => {
|
||||
expect(changedRun.run).toContain('. != "tests/e2e/ssh-startup-exec-readiness.spec.ts"')
|
||||
expect(changedRun.run).toContain('. != "tests/e2e/paired-startup-exec-readiness.spec.ts"')
|
||||
expect(changedRun.run).toContain('if [ "${#TEST_FILES[@]}" -eq 0 ]')
|
||||
expect(changedRun.run).toContain('pnpm run test:e2e "${TEST_FILES[@]}" --workers=1')
|
||||
expect(changedRun.run).toContain('grep -l \'@headful\' "${TEST_FILES[@]}"')
|
||||
expect(changedRun.run).toContain('E2E_PROJECT_ARGS+=(--project=electron-headful)')
|
||||
expect(changedRun.run).toContain(
|
||||
'pnpm run test:e2e "${TEST_FILES[@]}" --workers=1 "${E2E_PROJECT_ARGS[@]}"'
|
||||
)
|
||||
})
|
||||
|
||||
it('keeps startup-exec live parity in the isolated SSH lane', () => {
|
||||
|
||||
@@ -5,7 +5,7 @@ import {
|
||||
resolveEnvironment,
|
||||
resolveEnvironmentPairingOffer
|
||||
} from '../../src/shared/runtime-environment-store'
|
||||
import type { MemorySnapshot } from '../../src/shared/types'
|
||||
import type { MemorySnapshot } from '../../src/shared/process-stats-types'
|
||||
import type { RuntimeStatus } from '../../src/shared/runtime-types'
|
||||
|
||||
async function main(): Promise<void> {
|
||||
|
||||
@@ -96,7 +96,7 @@ import {
|
||||
WORKSPACE_SORT_OPTIONS as SORT_OPTIONS
|
||||
} from '../../../src/worktree/workspace-list-picker-options'
|
||||
import type { RepoSummary } from '../../../src/worktree/host-worktree-rpc-types'
|
||||
import type { WorkspaceStatusDefinition } from '../../../../src/shared/types'
|
||||
import type { WorkspaceStatusDefinition } from '../../../../src/shared/worktree/types'
|
||||
import { DEFAULT_MOBILE_WORKSPACE_STATUSES } from '../../../src/worktree/mobile-workspace-statuses'
|
||||
|
||||
function isErrorVerdict(v: ConnectionVerdict): boolean {
|
||||
|
||||
@@ -277,7 +277,8 @@ import {
|
||||
import { colors } from '../../../../src/theme/mobile-theme'
|
||||
import { QuickCommandsTabButton } from '../../../../src/session/QuickCommandsTabButton'
|
||||
import { styles } from '../../../../src/session/mobile-session-styles'
|
||||
import type { DiffComment, TerminalQuickCommand } from '../../../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../../../src/shared/diff-comment-types'
|
||||
import type { TerminalQuickCommand } from '../../../../../src/shared/terminal-quick-command-types'
|
||||
import type {
|
||||
DiffCommentActions,
|
||||
DiffNotesDelivery,
|
||||
|
||||
@@ -149,13 +149,13 @@ import {
|
||||
scheduleMobileTaskCopyFeedbackReset
|
||||
} from '../../../src/tasks/mobile-task-copy-feedback-timer'
|
||||
import type {
|
||||
BaseRefSearchResult,
|
||||
GitHubOwnerRepo,
|
||||
ProviderCheckSummary,
|
||||
PersistedTrustedOrcaHooks,
|
||||
SparsePreset,
|
||||
TuiAgent
|
||||
} from '../../../../src/shared/types'
|
||||
ProviderCheckSummary
|
||||
} from '../../../../src/shared/github/pull-request-types'
|
||||
import type { PersistedTrustedOrcaHooks } from '../../../../src/shared/orca-yaml-hook-types'
|
||||
import type { BaseRefSearchResult } from '../../../../src/shared/repo-types'
|
||||
import type { TuiAgent } from '../../../../src/shared/tui-agent'
|
||||
import type { SparsePreset } from '../../../../src/shared/worktree/create-types'
|
||||
import type { SshConnectionState } from '../../../../src/shared/ssh-types'
|
||||
import type { HostedReviewDecision } from '../../../../src/shared/hosted-review'
|
||||
import {
|
||||
|
||||
@@ -7,7 +7,7 @@ import {
|
||||
applyTerminalQuickCommandMutation,
|
||||
type TerminalQuickCommandMutation
|
||||
} from '../../src/shared/terminal-quick-commands'
|
||||
import type { TerminalQuickCommand } from '../../src/shared/types'
|
||||
import type { TerminalQuickCommand } from '../../src/shared/terminal-quick-command-types'
|
||||
import { handleMockFilePreviewRequest } from './mock-server-file-preview-data'
|
||||
import { handleMockGitRequest } from './mock-server-git-state'
|
||||
import { handleMockAccountRequest } from './mock-server-account-rpc'
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Image, StyleSheet, Text, View } from 'react-native'
|
||||
import type { ImageSourcePropType } from 'react-native'
|
||||
import { Terminal } from 'lucide-react-native'
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import Svg, { Defs, G, LinearGradient, Path, Stop } from 'react-native-svg'
|
||||
import { colors } from '../theme/mobile-theme'
|
||||
import { MOBILE_AGENT_CATALOG } from '../tasks/mobile-agent-catalog'
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { ActivityIndicator, FlatList, Pressable, Text, View } from 'react-native'
|
||||
import { RefreshCw } from 'lucide-react-native'
|
||||
import type { RefObject } from 'react'
|
||||
import type { DiffComment } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
import { colors } from '../theme/mobile-theme'
|
||||
import { MobileDiffReviewLine } from './MobileDiffReviewLine'
|
||||
import type {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { useMemo } from 'react'
|
||||
import { KeyboardAvoidingView, Platform, Pressable, Text, TextInput, View } from 'react-native'
|
||||
import { Check, Copy, FileText, Plus, Send, Trash2, X } from 'lucide-react-native'
|
||||
import type { DiffComment } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
import { colors } from '../theme/mobile-theme'
|
||||
import type { ActionSheetAction } from './ActionSheetModal'
|
||||
import { ActionSheetModal } from './ActionSheetModal'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Pressable, Text, View } from 'react-native'
|
||||
import { ArrowDown, ArrowUp } from 'lucide-react-native'
|
||||
import type { DiffComment } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
import { colors } from '../theme/mobile-theme'
|
||||
import type { MobileDiffReviewQueueItem } from '../session/mobile-diff-review-queue'
|
||||
import { MOBILE_GIT_STATUS_LABELS } from '../source-control/mobile-git-status'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Pressable, StyleSheet, Text, View } from 'react-native'
|
||||
import { MessageSquare } from 'lucide-react-native'
|
||||
import type { DiffComment } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
import type { MobileDiffLine } from '../session/mobile-diff-lines'
|
||||
import type { MobileHighlightedDiffLine } from '../session/mobile-file-syntax'
|
||||
import { mobileDiffLineNumber, mobileDiffLinePrefix } from '../source-control/mobile-diff-format'
|
||||
|
||||
@@ -30,7 +30,8 @@ import {
|
||||
type SetupHookTrust
|
||||
} from '../tasks/setup-hook-trust'
|
||||
import { isMobileTuiAgentEnabled } from '../tasks/mobile-tui-agents'
|
||||
import type { PersistedTrustedOrcaHooks, TuiAgent } from '../../../src/shared/types'
|
||||
import type { PersistedTrustedOrcaHooks } from '../../../src/shared/orca-yaml-hook-types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import type { SshConnectionState } from '../../../src/shared/ssh-types'
|
||||
import {
|
||||
NEW_WORKTREE_AGENT_OPTIONS as AGENT_OPTIONS,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { existsSync, readFileSync } from 'node:fs'
|
||||
import path from 'node:path'
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import { MOBILE_TUI_AGENT_FAVICON_DOMAINS } from '../tasks/mobile-tui-agents'
|
||||
|
||||
// Agents that render a hand-authored glyph in MobileAgentIcon and therefore
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import type { ImageSourcePropType } from 'react-native'
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
|
||||
// Why: mobile previously rendered these agent icons from Google's favicon
|
||||
// service, which is unreachable in some regions (e.g. mainland China) and
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import { MOBILE_AGENT_CATALOG } from '../tasks/mobile-agent-catalog'
|
||||
import { isMobileTuiAgentEnabled } from '../tasks/mobile-tui-agents'
|
||||
import { pickWorkspaceAgent } from '../tasks/workspace-agent-selection'
|
||||
|
||||
@@ -2,7 +2,7 @@ import { useCallback, useState } from 'react'
|
||||
import { ActivityIndicator, Pressable, Text, View } from 'react-native'
|
||||
import { GitMerge, Link2Off } from 'lucide-react-native'
|
||||
import { colors } from '../../theme/mobile-theme'
|
||||
import type { GitHubPRMergeMethod, PRInfo } from '../../../../src/shared/types'
|
||||
import type { GitHubPRMergeMethod, PRInfo } from '../../../../src/shared/github/pull-request-types'
|
||||
import type { RpcClient } from '../../transport/rpc-client'
|
||||
import type { MobilePrActions } from '../../session/use-mobile-pr-actions'
|
||||
import { unlinkMobilePr } from '../../source-control/mobile-pr-link'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { ActivityIndicator, ScrollView, Text, View } from 'react-native'
|
||||
import { colors } from '../../theme/mobile-theme'
|
||||
import type { PRCheckRunDetails } from '../../../../src/shared/types'
|
||||
import type { PRCheckRunDetails } from '../../../../src/shared/github/check-types'
|
||||
import { presentCheckDetail, type CheckDetailJob } from './pr-check-detail-content'
|
||||
import { mobilePrSidebarStyles as styles } from './mobile-pr-sidebar-styles'
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ import { useCallback, useEffect, useRef, useState } from 'react'
|
||||
import { ActivityIndicator, Linking, Pressable, Text, View } from 'react-native'
|
||||
import { ChevronDown, ChevronRight, ExternalLink, RotateCw, Sparkles } from 'lucide-react-native'
|
||||
import { colors } from '../../theme/mobile-theme'
|
||||
import type { PRCheckDetail } from '../../../../src/shared/types'
|
||||
import type { PRCheckDetail } from '../../../../src/shared/github/check-types'
|
||||
import type { RpcClient } from '../../transport/rpc-client'
|
||||
import { fetchPRCheckDetails, type GitHubPrRepoSlug } from '../../session/github-pr-rpc'
|
||||
import type { MobilePrActions } from '../../session/use-mobile-pr-actions'
|
||||
|
||||
@@ -1,7 +1,11 @@
|
||||
import { memo, useState } from 'react'
|
||||
import { Image, Linking, Pressable, Text, View } from 'react-native'
|
||||
import { Check, CornerDownRight, ExternalLink, Pencil, Trash2, Undo2 } from 'lucide-react-native'
|
||||
import type { GitHubReaction, GitHubReactionContent, PRComment } from '../../../../src/shared/types'
|
||||
import type {
|
||||
GitHubReaction,
|
||||
GitHubReactionContent,
|
||||
PRComment
|
||||
} from '../../../../src/shared/github/comment-types'
|
||||
import { colors } from '../../theme/mobile-theme'
|
||||
import { canEditComment, isResolvableComment } from '../../session/pr-comment-actions'
|
||||
import { ConfirmModal } from '../ConfirmModal'
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import { createElement } from 'react'
|
||||
import { act, create, type ReactTestRenderer } from 'react-test-renderer'
|
||||
import { afterEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { GitHubWorkItemDetails, PRComment } from '../../../../src/shared/types'
|
||||
import type { PRComment } from '../../../../src/shared/github/comment-types'
|
||||
import type { GitHubWorkItemDetails } from '../../../../src/shared/github/work-item-types'
|
||||
import { PRCommentsSection } from './PRCommentsSection'
|
||||
|
||||
vi.mock('react-native', () => ({
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import { useMemo, useState } from 'react'
|
||||
import { ActivityIndicator, Pressable, Text, View } from 'react-native'
|
||||
import { ChevronDown, ChevronRight } from 'lucide-react-native'
|
||||
import type { GitHubWorkItemDetails, PRState } from '../../../../src/shared/types'
|
||||
import type { PRState } from '../../../../src/shared/github/pull-request-types'
|
||||
import type { GitHubWorkItemDetails } from '../../../../src/shared/github/work-item-types'
|
||||
import type { GitHubPrRepoSlug } from '../../session/github-pr-rpc'
|
||||
import { colors } from '../../theme/mobile-theme'
|
||||
import { canAddRootComment } from '../../session/pr-comment-actions'
|
||||
|
||||
@@ -3,7 +3,7 @@ import { ActivityIndicator, Pressable, ScrollView, Text, View } from 'react-nati
|
||||
import * as Clipboard from 'expo-clipboard'
|
||||
import { Check, Copy, FileWarning, Sparkles } from 'lucide-react-native'
|
||||
import { colors } from '../../theme/mobile-theme'
|
||||
import type { PRInfo } from '../../../../src/shared/types'
|
||||
import type { PRInfo } from '../../../../src/shared/github/pull-request-types'
|
||||
import { PRSection } from './PRSection'
|
||||
import { resolveConflictDisplay } from './pr-conflict-presentation'
|
||||
import { prConflictStyles as styles } from './pr-conflict-styles'
|
||||
|
||||
@@ -2,7 +2,7 @@ import { useMemo, useState } from 'react'
|
||||
import { ActivityIndicator, Pressable, Text, View } from 'react-native'
|
||||
import { UserPlus, X } from 'lucide-react-native'
|
||||
import { colors } from '../../theme/mobile-theme'
|
||||
import type { GitHubWorkItemDetails } from '../../../../src/shared/types'
|
||||
import type { GitHubWorkItemDetails } from '../../../../src/shared/github/work-item-types'
|
||||
import type { RpcClient } from '../../transport/rpc-client'
|
||||
import type { MobilePrActions } from '../../session/use-mobile-pr-actions'
|
||||
import { isPrSidebarDetailsPlaceholder } from '../../session/mobile-pr-sidebar-state'
|
||||
|
||||
@@ -2,7 +2,8 @@ import { useState } from 'react'
|
||||
import { ActivityIndicator, Pressable, Text, TextInput, View } from 'react-native'
|
||||
import { ArrowRight, ExternalLink, Pencil } from 'lucide-react-native'
|
||||
import { colors } from '../../theme/mobile-theme'
|
||||
import type { GitHubWorkItemDetails, PRInfo } from '../../../../src/shared/types'
|
||||
import type { PRInfo } from '../../../../src/shared/github/pull-request-types'
|
||||
import type { GitHubWorkItemDetails } from '../../../../src/shared/github/work-item-types'
|
||||
import type { MobilePrTitleAction } from '../../session/use-mobile-pr-title-action'
|
||||
import { prStateBadge } from './pr-checks-presentation'
|
||||
import { statusColor } from './pr-sidebar-status-color'
|
||||
|
||||
@@ -2,7 +2,7 @@ import { useEffect, useMemo, useState } from 'react'
|
||||
import { ActivityIndicator, Pressable, Text, TextInput, View } from 'react-native'
|
||||
import { Check } from 'lucide-react-native'
|
||||
import { colors } from '../../theme/mobile-theme'
|
||||
import type { GitHubAssignableUser } from '../../../../src/shared/types'
|
||||
import type { GitHubAssignableUser } from '../../../../src/shared/github/pull-request-types'
|
||||
import type { RpcClient } from '../../transport/rpc-client'
|
||||
import { fetchAssignableUsers } from '../../session/github-pr-rpc'
|
||||
import { BottomDrawer } from '../BottomDrawer'
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { GitHubPRMergeMethod, PRState } from '../../../../src/shared/types'
|
||||
import type { GitHubPRMergeMethod, PRState } from '../../../../src/shared/github/pull-request-types'
|
||||
|
||||
// Which actions the PR actions section may offer for a given PR state. Merged PRs
|
||||
// expose only unlink (+ open-on-host elsewhere); closed PRs add reopen; open/draft
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { PRInfo } from '../../../../src/shared/types'
|
||||
import type { PRInfo } from '../../../../src/shared/github/pull-request-types'
|
||||
|
||||
type MobilePRAutoMergeAvailabilityInput = Pick<
|
||||
PRInfo,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { PRCheckRunDetails } from '../../../../src/shared/types'
|
||||
import type { PRCheckRunDetails } from '../../../../src/shared/github/check-types'
|
||||
import { presentCheckDetail } from './pr-check-detail-content'
|
||||
|
||||
function details(over: Partial<PRCheckRunDetails>): PRCheckRunDetails {
|
||||
|
||||
@@ -3,7 +3,7 @@ import type {
|
||||
PRCheckJob,
|
||||
PRCheckRunDetails,
|
||||
PRCheckStep
|
||||
} from '../../../../src/shared/types'
|
||||
} from '../../../../src/shared/github/check-types'
|
||||
|
||||
// Pure mapping from the github.prCheckDetails payload to the rows the mobile
|
||||
// expanded check detail renders. No React/native imports so it stays unit-testable
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { PRCheckDetail } from '../../../../src/shared/types'
|
||||
import type { PRCheckDetail } from '../../../../src/shared/github/check-types'
|
||||
import {
|
||||
checkOutcome,
|
||||
firstFailingCheckKey,
|
||||
|
||||
@@ -1,4 +1,8 @@
|
||||
import type { PRCheckDetail, PRState, ProviderCheckSummary } from '../../../../src/shared/types'
|
||||
import type { PRCheckDetail } from '../../../../src/shared/github/check-types'
|
||||
import type {
|
||||
PRState,
|
||||
ProviderCheckSummary
|
||||
} from '../../../../src/shared/github/pull-request-types'
|
||||
import {
|
||||
classifyCheckOutcome,
|
||||
summarizeProviderChecks,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { PRInfo } from '../../../../src/shared/types'
|
||||
import type { PRInfo } from '../../../../src/shared/github/pull-request-types'
|
||||
import {
|
||||
buildMergeabilityRefreshCommands,
|
||||
hasMergeConflicts,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { PRInfo } from '../../../../src/shared/types'
|
||||
import type { PRInfo } from '../../../../src/shared/github/pull-request-types'
|
||||
|
||||
// Pure presentation logic for the PR sidebar's conflicting-files section. No
|
||||
// React/native imports so it is unit-testable under the node Vitest config (KTD5).
|
||||
|
||||
@@ -4,7 +4,7 @@ import * as Clipboard from 'expo-clipboard'
|
||||
import { Check, Copy, Pencil, Play, Trash2 } from 'lucide-react-native'
|
||||
import { colors, spacing, typography } from '../theme/mobile-theme'
|
||||
import { MobileAgentIcon } from '../components/MobileAgentIcon'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/types'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/terminal-quick-command-types'
|
||||
import {
|
||||
getQuickCommandDisplayPreview,
|
||||
getTerminalQuickCommandBody,
|
||||
|
||||
@@ -3,7 +3,8 @@ import { Check, Plus, Search } from 'lucide-react-native'
|
||||
import { colors, spacing } from '../theme/mobile-theme'
|
||||
import { MobileAgentIcon } from '../components/MobileAgentIcon'
|
||||
import { MOBILE_AGENT_CATALOG } from '../tasks/mobile-agent-catalog'
|
||||
import type { TerminalQuickCommand, TuiAgent } from '../../../src/shared/types'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/terminal-quick-command-types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import { supportsTerminalAgentQuickCommand } from '../terminal/quick-commands'
|
||||
import { QuickCommandRow } from './QuickCommandRow'
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { createElement, type ReactNode } from 'react'
|
||||
import { act, create, type ReactTestRenderer } from 'react-test-renderer'
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/types'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/terminal-quick-command-types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import { MAX_QUICK_COMMANDS } from '../terminal/quick-commands'
|
||||
import { QuickCommandsSheet } from './QuickCommandsSheet'
|
||||
|
||||
@@ -4,7 +4,7 @@ import { ChevronLeft } from 'lucide-react-native'
|
||||
import { colors, spacing } from '../theme/mobile-theme'
|
||||
import { BottomDrawer } from '../components/BottomDrawer'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/types'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/terminal-quick-command-types'
|
||||
import {
|
||||
getQuickCommandPreview,
|
||||
MAX_QUICK_COMMANDS,
|
||||
|
||||
@@ -13,7 +13,7 @@ import {
|
||||
resolveTuiAgentLaunchEnv
|
||||
} from '../../../src/shared/tui-agent-launch-defaults'
|
||||
import { normalizeAiVaultResumeFilePath } from '../../../src/shared/ai-vault-resume-path'
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import { parseWslUncPath } from '../../../src/shared/wsl-paths'
|
||||
import { resolveWindowsShellStartupFamily } from '../../../src/shared/windows-terminal-shell'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
|
||||
@@ -1,4 +1,8 @@
|
||||
import type { GitHubReaction, GitHubReactionContent, PRComment } from '../../../src/shared/types'
|
||||
import type {
|
||||
GitHubReaction,
|
||||
GitHubReactionContent,
|
||||
PRComment
|
||||
} from '../../../src/shared/github/comment-types'
|
||||
import { isRecord, readBoolean, readNumber, readString } from './github-pr-value-readers'
|
||||
|
||||
// Defensive parsers for the PR conversation comments carried by
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { GitHubPRMergeMethod } from '../../../src/shared/types'
|
||||
import type { GitHubPRMergeMethod } from '../../../src/shared/github/pull-request-types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import { buildGithubPrParams, githubPrRepoSlugParam, type GitHubPrRepoSlug } from './github-pr-rpc'
|
||||
|
||||
|
||||
@@ -1,15 +1,19 @@
|
||||
import type {
|
||||
GitHubAssignableUser,
|
||||
GitHubPRReviewSummary,
|
||||
GitHubWorkItem,
|
||||
GitHubWorkItemDetails,
|
||||
PRCheckAnnotation,
|
||||
PRCheckDetail,
|
||||
PRCheckJob,
|
||||
PRCheckRunDetails,
|
||||
PRCheckStep,
|
||||
PRCheckStep
|
||||
} from '../../../src/shared/github/check-types'
|
||||
import type {
|
||||
GitHubAssignableUser,
|
||||
GitHubPRReviewSummary,
|
||||
PRInfo
|
||||
} from '../../../src/shared/types'
|
||||
} from '../../../src/shared/github/pull-request-types'
|
||||
import type {
|
||||
GitHubWorkItem,
|
||||
GitHubWorkItemDetails
|
||||
} from '../../../src/shared/github/work-item-types'
|
||||
import { readPRComments } from './github-pr-comment-parsers'
|
||||
import type { HostedReviewInfo } from '../../../src/shared/hosted-review'
|
||||
import {
|
||||
|
||||
@@ -1,10 +1,6 @@
|
||||
import type {
|
||||
GitHubAssignableUser,
|
||||
GitHubWorkItemDetails,
|
||||
PRCheckDetail,
|
||||
PRCheckRunDetails,
|
||||
PRInfo
|
||||
} from '../../../src/shared/types'
|
||||
import type { PRCheckDetail, PRCheckRunDetails } from '../../../src/shared/github/check-types'
|
||||
import type { GitHubAssignableUser, PRInfo } from '../../../src/shared/github/pull-request-types'
|
||||
import type { GitHubWorkItemDetails } from '../../../src/shared/github/work-item-types'
|
||||
import type { HostedReviewInfo } from '../../../src/shared/hosted-review'
|
||||
import {
|
||||
normalizeGitHubPRForBranchOutcome,
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
import type { PRCheckDetail } from '../../../src/shared/github/check-types'
|
||||
import type {
|
||||
CheckStatus,
|
||||
GitHubAssignableUser,
|
||||
ProviderCheckSummary,
|
||||
GitHubPRMergeMethod,
|
||||
GitHubPRMergeMethodSettings,
|
||||
GitHubPRReviewSummary,
|
||||
GitHubRepositoryIdentity,
|
||||
PRCheckDetail,
|
||||
PRMergeableState,
|
||||
PRReviewDecision,
|
||||
PRState
|
||||
} from '../../../src/shared/types'
|
||||
PRState,
|
||||
ProviderCheckSummary
|
||||
} from '../../../src/shared/github/pull-request-types'
|
||||
import type { HostedReviewProvider } from '../../../src/shared/hosted-review'
|
||||
|
||||
// Primitive + enum value readers shared by the github.* PR parsers. Each narrows
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { DiffComment } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
import {
|
||||
clearSentMobileDiffComments,
|
||||
countUnsentMobileDiffComments,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { DiffComment } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
|
||||
export type UpdateMobileDiffCommentInput = {
|
||||
id: string
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { DiffComment } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
import {
|
||||
addMobileDiffComment,
|
||||
formatDiffComments,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { DiffComment, DiffReviewScope } from '../../../src/shared/types'
|
||||
import type { DiffComment, DiffReviewScope } from '../../../src/shared/diff-comment-types'
|
||||
import { formatDiffComment, formatDiffComments } from '../../../src/shared/diff-comments-format'
|
||||
|
||||
export { formatDiffComment, formatDiffComments }
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { DiffReviewScope } from '../../../src/shared/types'
|
||||
import type { DiffReviewScope } from '../../../src/shared/diff-comment-types'
|
||||
import type { MobileGitStagingArea } from '../source-control/mobile-git-status'
|
||||
import {
|
||||
createMobileDiffReviewFileKey,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { DiffComment, MobileDiffReviewState } from '../../../src/shared/types'
|
||||
import type { DiffComment, MobileDiffReviewState } from '../../../src/shared/diff-comment-types'
|
||||
import type { MobileGitBranchChangeEntry } from '../source-control/mobile-branch-compare'
|
||||
import type { MobileGitStatusEntry } from '../source-control/mobile-git-status'
|
||||
import {
|
||||
|
||||
@@ -1,4 +1,8 @@
|
||||
import type { DiffComment, DiffReviewScope, MobileDiffReviewState } from '../../../src/shared/types'
|
||||
import type {
|
||||
DiffComment,
|
||||
DiffReviewScope,
|
||||
MobileDiffReviewState
|
||||
} from '../../../src/shared/diff-comment-types'
|
||||
import type { MobileGitBranchChangeEntry } from '../source-control/mobile-branch-compare'
|
||||
import {
|
||||
isMobileGitDiscardableEntry,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { DiffComment, MobileDiffReviewState } from '../../../src/shared/types'
|
||||
import type { DiffComment, MobileDiffReviewState } from '../../../src/shared/diff-comment-types'
|
||||
import type { MobileGitBranchCompareResult } from '../source-control/mobile-branch-compare'
|
||||
import type { MobileGitStatusResult } from '../source-control/mobile-git-status'
|
||||
import type { MobileDiffLine } from './mobile-diff-lines'
|
||||
|
||||
@@ -2,7 +2,7 @@ import type {
|
||||
DiffReviewScope,
|
||||
MobileDiffReviewFileState,
|
||||
MobileDiffReviewState
|
||||
} from '../../../src/shared/types'
|
||||
} from '../../../src/shared/diff-comment-types'
|
||||
|
||||
export type MobileDiffReviewFileDescriptor = {
|
||||
key: string
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import {
|
||||
filterEnabledMobileTuiAgents,
|
||||
isMobileTuiAgent,
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
import type { GitHubWorkItemDetails, PRCheckDetail, PRInfo } from '../../../src/shared/types'
|
||||
import type { PRCheckDetail } from '../../../src/shared/github/check-types'
|
||||
import type { PRInfo } from '../../../src/shared/github/pull-request-types'
|
||||
import type { GitHubWorkItemDetails } from '../../../src/shared/github/work-item-types'
|
||||
import type { GitHubPrReadOutcome, GitHubPrRepoSlug } from './github-pr-rpc'
|
||||
import { resolveLinkedPrNumber } from './mobile-pr-sidebar-resolve'
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import type { DiffComment, TuiAgent } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import type { AgentStatusEntry } from '../../../src/shared/agent-status-types'
|
||||
import type { MobileBrowserTab } from '../browser/MobileBrowserPane'
|
||||
import type { MobileTerminalTheme } from '../terminal/terminal-webview-contract'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { AgentStatusEntry } from '../../../src/shared/agent-status-types'
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import type { MobileSessionTab } from './mobile-session-route-types'
|
||||
import {
|
||||
getMobileSessionTabTitle,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { stripLeadingAgentTitleDecorationOrEmpty } from '../../../src/shared/agent-title-decoration'
|
||||
import { resolveExplicitTerminalTitleAgentType } from '../../../src/shared/terminal-title-agent-type'
|
||||
import type { AgentStatusEntry } from '../../../src/shared/agent-status-types'
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import { isBlankBrowserUrl } from '../browser/browser-url'
|
||||
import type { MobileSessionTab } from './mobile-session-route-types'
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { GitHubPRMergeMethod } from '../../../src/shared/types'
|
||||
import type { GitHubPRMergeMethod } from '../../../src/shared/github/pull-request-types'
|
||||
import type { GitHubPrMutationOutcome } from './github-pr-mutations'
|
||||
import type { GitHubPrRepoSlug } from './github-pr-rpc'
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { GitHubPRMergeMethod, PRState } from '../../../src/shared/types'
|
||||
import type { GitHubPRMergeMethod, PRState } from '../../../src/shared/github/pull-request-types'
|
||||
import { githubRepoIdentityKey } from '../../../src/shared/github/repository-identity-key'
|
||||
import { classifyPrSidebarFailure } from './mobile-pr-sidebar-state'
|
||||
import { createOptimisticField, type OptimisticField } from './optimistic-write-sequence'
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { PRCheckDetail } from '../../../src/shared/types'
|
||||
import type { PRCheckDetail } from '../../../src/shared/github/check-types'
|
||||
import {
|
||||
buildFixChecksPrompt,
|
||||
buildResolveConflictsPrompt,
|
||||
|
||||
@@ -3,7 +3,7 @@ import {
|
||||
getBrokenChecks
|
||||
} from '../../../src/shared/pr-checks-fix-prompt'
|
||||
import { buildResolvePullRequestConflictsPrompt } from '../../../src/shared/source-control-conflict-prompts'
|
||||
import type { PRCheckDetail } from '../../../src/shared/types'
|
||||
import type { PRCheckDetail } from '../../../src/shared/github/check-types'
|
||||
|
||||
// Pure prompt builders for the mobile PR sidebar's "Fix checks with AI" /
|
||||
// "Resolve conflicts with AI" triage actions. Kept free of React/native imports
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { PRComment } from '../../../src/shared/types'
|
||||
import type { PRComment } from '../../../src/shared/github/comment-types'
|
||||
import {
|
||||
buildAddRootCommentParams,
|
||||
buildDeleteCommentParams,
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import type { GitHubOwnerRepo, PRComment, PRState } from '../../../src/shared/types'
|
||||
import type { PRComment } from '../../../src/shared/github/comment-types'
|
||||
import type { GitHubOwnerRepo, PRState } from '../../../src/shared/github/pull-request-types'
|
||||
|
||||
// Pure helpers for the interactive PR comment timeline (reply / resolve / add
|
||||
// root comment). Kept free of React/native imports so they unit-test under the
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { PRState } from '../../../src/shared/types'
|
||||
import type { PRState } from '../../../src/shared/github/pull-request-types'
|
||||
|
||||
// Pure helpers for the inline PR-title edit affordance. Kept free of React/native
|
||||
// imports so they unit-test under the node Vitest config, mirroring the other
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import type {
|
||||
TerminalQuickCommand,
|
||||
TerminalQuickCommandAction,
|
||||
TerminalQuickCommandScope,
|
||||
TuiAgent
|
||||
} from '../../../src/shared/types'
|
||||
TerminalQuickCommandScope
|
||||
} from '../../../src/shared/terminal-quick-command-types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import {
|
||||
isAgentQuickCommand,
|
||||
MAX_QUICK_COMMAND_AGENT_PROMPT_LENGTH,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { useCallback, type Dispatch, type SetStateAction } from 'react'
|
||||
import type { DiffComment, MobileDiffReviewState } from '../../../src/shared/types'
|
||||
import type { DiffComment, MobileDiffReviewState } from '../../../src/shared/diff-comment-types'
|
||||
import { triggerError, triggerSuccess } from '../platform/haptics'
|
||||
import type { ConnectionState } from '../transport/types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from 'react'
|
||||
import type { FlatList } from 'react-native'
|
||||
import type { DiffComment } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
import type { ConnectionState } from '../transport/types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import { getWorktreeLabel } from './worktree-label'
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { createElement } from 'react'
|
||||
import { act, create, type ReactTestRenderer } from 'react-test-renderer'
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { DiffComment } from '../../../src/shared/types'
|
||||
import type { DiffComment } from '../../../src/shared/diff-comment-types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import type { ReviewScreenState } from './mobile-diff-review-screen-model'
|
||||
import {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useCallback, type Dispatch, type SetStateAction } from 'react'
|
||||
import * as Clipboard from 'expo-clipboard'
|
||||
import type { DiffComment, MobileDiffReviewState } from '../../../src/shared/types'
|
||||
import type { DiffComment, MobileDiffReviewState } from '../../../src/shared/diff-comment-types'
|
||||
import type { ConnectionState } from '../transport/types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import { triggerSuccess } from '../platform/haptics'
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { useCallback, useMemo, useRef, useState } from 'react'
|
||||
import type { PRComment } from '../../../src/shared/types'
|
||||
import type { PRComment } from '../../../src/shared/github/comment-types'
|
||||
import type { ConnectionState } from '../transport/types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import type { GitHubPrRepoSlug } from './github-pr-rpc'
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import { describe, expect, it, vi } from 'vitest'
|
||||
import type { GitHubWorkItemDetails, PRCheckDetail, PRInfo } from '../../../src/shared/types'
|
||||
import type { PRCheckDetail } from '../../../src/shared/github/check-types'
|
||||
import type { PRInfo } from '../../../src/shared/github/pull-request-types'
|
||||
import type { GitHubWorkItemDetails } from '../../../src/shared/github/work-item-types'
|
||||
import type { HostedReviewInfo } from '../../../src/shared/hosted-review'
|
||||
import type { GitHubPrReadOutcome } from './github-pr-rpc'
|
||||
import {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { createElement } from 'react'
|
||||
import { act, create, type ReactTestRenderer } from 'react-test-renderer'
|
||||
import { afterEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/types'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/terminal-quick-command-types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import { LogicalClientCutoverError } from '../transport/stable-logical-rpc-client'
|
||||
import type { RpcResponse } from '../transport/types'
|
||||
|
||||
@@ -2,7 +2,7 @@ import { useCallback, useEffect, useRef, useState } from 'react'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import { isLogicalClientCutoverError } from '../transport/stable-logical-rpc-client'
|
||||
import type { RpcFailure, RpcResponse, RpcSuccess } from '../transport/types'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/types'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/terminal-quick-command-types'
|
||||
import {
|
||||
applyTerminalQuickCommandMutation,
|
||||
parseNormalizedTerminalQuickCommands,
|
||||
|
||||
@@ -11,7 +11,7 @@ import {
|
||||
type MobileCommitRow
|
||||
} from './mobile-git-history'
|
||||
import { resolveMobileHistoryScreenView } from './mobile-history-screen-state'
|
||||
import type { GitBranchChangeEntry } from '../../../src/shared/types'
|
||||
import type { GitBranchChangeEntry } from '../../../src/shared/git-diff-compare-types'
|
||||
|
||||
type Props = {
|
||||
client: RpcClient | null
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, expectTypeOf, it } from 'vitest'
|
||||
import type { GitBranchCompareResult } from '../../../src/shared/types'
|
||||
import type { GitBranchCompareResult } from '../../../src/shared/git-diff-compare-types'
|
||||
import {
|
||||
buildMobileBranchCompareSection,
|
||||
canOpenMobileBranchCompareDiff,
|
||||
|
||||
@@ -2,7 +2,7 @@ import type {
|
||||
GitBranchChangeEntry,
|
||||
GitBranchCompareResult,
|
||||
GitBranchCompareSummary
|
||||
} from '../../../src/shared/types'
|
||||
} from '../../../src/shared/git-diff-compare-types'
|
||||
|
||||
export type MobileGitBranchChangeEntry = GitBranchChangeEntry
|
||||
export type MobileGitBranchCompareSummary = GitBranchCompareSummary
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import { describe, it, expect } from 'vitest'
|
||||
import type { PRCheckDetail, PRComment, PRInfo } from '../../../src/shared/types'
|
||||
import type { PRCheckDetail } from '../../../src/shared/github/check-types'
|
||||
import type { PRComment } from '../../../src/shared/github/comment-types'
|
||||
import type { PRInfo } from '../../../src/shared/github/pull-request-types'
|
||||
import type { PrSidebarState } from '../session/mobile-pr-sidebar-state'
|
||||
import { buildMobilePrChipSummary, countUnresolvedReviewThreads } from './mobile-pr-chip-summary'
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { PRComment } from '../../../src/shared/types'
|
||||
import type { PRComment } from '../../../src/shared/github/comment-types'
|
||||
import type { PrSidebarState } from '../session/mobile-pr-sidebar-state'
|
||||
import { summarizeProviderChecks } from '../../../src/shared/provider-check-summary'
|
||||
import {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import { createWorktreeWithNameRetry, type WorktreeCreateResult } from './worktree-create-retry'
|
||||
import {
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { GitHubWorkItem, GitLabWorkItem, LinearIssue } from '../../../src/shared/types'
|
||||
import type { GitHubWorkItem } from '../../../src/shared/github/work-item-types'
|
||||
import type { GitLabWorkItem } from '../../../src/shared/gitlab-types'
|
||||
import type { LinearIssue } from '../../../src/shared/linear/issue-types'
|
||||
import {
|
||||
buildGitHubLinkedWorkItem,
|
||||
buildGitLabLinkedWorkItem,
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
import type { GitHubWorkItem, GitLabWorkItem, LinearIssue } from '../../../src/shared/types'
|
||||
import type { GitHubWorkItem } from '../../../src/shared/github/work-item-types'
|
||||
import type { GitLabWorkItem } from '../../../src/shared/gitlab-types'
|
||||
import type { LinearIssue } from '../../../src/shared/linear/issue-types'
|
||||
import { getLinearIssueWorkspaceName } from '../../../src/shared/workspace-name'
|
||||
import {
|
||||
buildGitHubWorkspaceSource,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import type { RpcSuccess } from '../transport/types'
|
||||
import type { GitHubPrStartPoint } from '../../../src/shared/types'
|
||||
import type { GitHubPrStartPoint } from '../../../src/shared/worktree/types'
|
||||
|
||||
// The resolved start point for a linked PR/MR: the base branch to create from
|
||||
// plus the optional review-compare ref, push target, and exact branch name.
|
||||
|
||||
@@ -2,7 +2,7 @@ import { describe, expect, it } from 'vitest'
|
||||
import { buildGitHubCheckSummary, type GitHubCheckLike } from './github-check-summary'
|
||||
import { buildGitLabCheckSummary } from './gitlab-check-summary'
|
||||
import { summarizeProviderChecks } from '../../../src/shared/provider-check-summary'
|
||||
import type { ProviderCheckSummary } from '../../../src/shared/types'
|
||||
import type { ProviderCheckSummary } from '../../../src/shared/github/pull-request-types'
|
||||
|
||||
describe('buildGitHubCheckSummary', () => {
|
||||
it('returns none for empty check lists', () => {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { summarizeProviderChecks } from '../../../src/shared/provider-check-summary'
|
||||
import type { ProviderCheckSummary } from '../../../src/shared/types'
|
||||
import type { ProviderCheckSummary } from '../../../src/shared/github/pull-request-types'
|
||||
|
||||
export type GitHubCheckLike = {
|
||||
status: string
|
||||
|
||||
@@ -3,7 +3,7 @@ import {
|
||||
mapGitLabPipelineJobStatusToConclusion
|
||||
} from '../../../src/shared/gitlab-pipeline-checks'
|
||||
import { summarizeProviderChecks } from '../../../src/shared/provider-check-summary'
|
||||
import type { ProviderCheckSummary } from '../../../src/shared/types'
|
||||
import type { ProviderCheckSummary } from '../../../src/shared/github/pull-request-types'
|
||||
|
||||
type GitLabPipelineJobLike = { status: string }
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import {
|
||||
MOBILE_TUI_AGENT_AUTO_PICK_ORDER,
|
||||
MOBILE_TUI_AGENT_FAVICON_DOMAINS,
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
import type { ProviderCheckSummary, PRMergeableState } from '../../../src/shared/types'
|
||||
import type {
|
||||
PRMergeableState,
|
||||
ProviderCheckSummary
|
||||
} from '../../../src/shared/github/pull-request-types'
|
||||
import { getProviderChecksLabel } from '../../../src/shared/provider-check-summary'
|
||||
|
||||
export type MobileHostedReviewStatus = {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
|
||||
// Why: mobile tests run from the mobile package only, so runtime imports of
|
||||
// desktop shared modules can break Vitest transforms in CI. Keep this list
|
||||
|
||||
@@ -6,7 +6,7 @@ import {
|
||||
trustedOrcaHooksWithSetupApproval,
|
||||
wasSetupHookPreviouslyApproved
|
||||
} from './setup-hook-trust'
|
||||
import type { PersistedTrustedOrcaHooks } from '../../../src/shared/types'
|
||||
import type { PersistedTrustedOrcaHooks } from '../../../src/shared/orca-yaml-hook-types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
|
||||
describe('setup hook trust', () => {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { PersistedTrustedOrcaHooks } from '../../../src/shared/types'
|
||||
import type { PersistedTrustedOrcaHooks } from '../../../src/shared/orca-yaml-hook-types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
|
||||
export type SetupHookTrust = {
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
import type {
|
||||
BaseRefSearchResult,
|
||||
GitHubWorkItem,
|
||||
GitLabWorkItem,
|
||||
LinearIssue
|
||||
} from '../../../src/shared/types'
|
||||
import type { GitHubWorkItem } from '../../../src/shared/github/work-item-types'
|
||||
import type { GitLabWorkItem } from '../../../src/shared/gitlab-types'
|
||||
import type { LinearIssue } from '../../../src/shared/linear/issue-types'
|
||||
import type { BaseRefSearchResult } from '../../../src/shared/repo-types'
|
||||
import {
|
||||
isSmartWorkspaceSourceQueryWithinLimit,
|
||||
type SmartNameMode
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import type { GitHubWorkItem, GitLabWorkItem } from '../../../src/shared/types'
|
||||
import type { GitHubWorkItem } from '../../../src/shared/github/work-item-types'
|
||||
import type { GitLabWorkItem } from '../../../src/shared/gitlab-types'
|
||||
import {
|
||||
normalizeGitHubLinkQuery,
|
||||
parseGitHubIssueOrPRLink,
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
import type {
|
||||
BaseRefSearchResult,
|
||||
GitHubWorkItem,
|
||||
GitLabWorkItem,
|
||||
LinearIssue
|
||||
} from '../../../src/shared/types'
|
||||
import type { GitHubWorkItem } from '../../../src/shared/github/work-item-types'
|
||||
import type { GitLabWorkItem } from '../../../src/shared/gitlab-types'
|
||||
import type { LinearIssue } from '../../../src/shared/linear/issue-types'
|
||||
import type { BaseRefSearchResult } from '../../../src/shared/repo-types'
|
||||
import type { RpcClient } from '../transport/rpc-client'
|
||||
import type { RpcSuccess } from '../transport/types'
|
||||
import { extractLinearIssueReadItems } from './linear-mobile-issue-read'
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import { useCallback, useMemo, useRef, useState } from 'react'
|
||||
import type { GitHubWorkItem, GitLabWorkItem, LinearIssue } from '../../../src/shared/types'
|
||||
import type { GitHubWorkItem } from '../../../src/shared/github/work-item-types'
|
||||
import type { GitLabWorkItem } from '../../../src/shared/gitlab-types'
|
||||
import type { LinearIssue } from '../../../src/shared/linear/issue-types'
|
||||
import { resolveComposerManualBranchNameChange } from '../../../src/shared/composer-branch-selection'
|
||||
import { resolveGitHubWorkItemIdentity } from '../../../src/shared/new-workspace/github-work-item-identity'
|
||||
import { getForkPushWarning } from '../../../src/shared/new-workspace/fork-push-warning'
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import { useCallback, useEffect, useMemo, useRef, useState } from 'react'
|
||||
import type { GitHubWorkItem, GitLabWorkItem } from '../../../src/shared/types'
|
||||
import type { GitHubWorkItem } from '../../../src/shared/github/work-item-types'
|
||||
import type { GitLabWorkItem } from '../../../src/shared/gitlab-types'
|
||||
import {
|
||||
buildSmartWorkspaceSourceRows,
|
||||
getSmartWorkspaceEmptyHint,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { TuiAgent } from '../../../src/shared/types'
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import {
|
||||
filterEnabledMobileTuiAgents,
|
||||
isMobileTuiAgent,
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import type { TuiAgent } from '../../../src/shared/tui-agent'
|
||||
import type {
|
||||
CreateSparseCheckoutRequest,
|
||||
GitPushTarget,
|
||||
SetupDecision,
|
||||
TuiAgent
|
||||
} from '../../../src/shared/types'
|
||||
SetupDecision
|
||||
} from '../../../src/shared/worktree/create-types'
|
||||
import type { GitPushTarget } from '../../../src/shared/worktree/types'
|
||||
import { getWorkspaceSourceName } from '../../../src/shared/new-workspace/workspace-source'
|
||||
import { resolveMobileWorkspaceCreateName } from './mobile-workspace-name'
|
||||
import type { WorkspaceAgentChoice } from './workspace-agent-selection'
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/types'
|
||||
import type { TerminalQuickCommand } from '../../../src/shared/terminal-quick-command-types'
|
||||
import {
|
||||
buildMobileQuickCommandLaunch,
|
||||
getQuickCommandDisplayPreview,
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user