Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 15 additions & 13 deletions docs/testing/perspectives/INDEX.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Test Perspectives Index

> Auto-generated: 2026-10-17T08:29:57+09:00
> Total sources: 58
> Total physical files: 104
> Total sections: 616
> Total cases: 3715
> Auto-generated: 2026-10-27T21:15:38+09:00
> Total sources: 59
> Total physical files: 105
> Total sections: 625
> Total cases: 3742

## Source File -> Perspectives (Forward Lookup)

Expand All @@ -27,12 +27,12 @@
| `src/dataSource.ts` | single-file | `archive/src/dataSource-test/2026-05-02-pre-sharding-dataSource-test.md` | 1 | 25 | 149 | 2026-04-04 |
| `src/dataSource.ts` | sharded | `src/dataSource-test/INDEX.md` | 9 | 44 | 315 | 2026-09-13 |
| `src/diffDocProvider.ts` | single-file | `src/diffDocProvider-test.md` | 1 | 7 | 33 | 2026-07-04 |
| `src/extension.ts` | single-file | `src/extension-test.md` | 1 | 9 | 32 | 2026-09-12 |
| `src/extension.ts` | single-file | `src/extension-test.md` | 1 | 10 | 33 | 2026-10-27 |
| `src/extensionState.ts` | single-file | `src/extensionState-test.md` | 1 | 14 | 42 | 2026-07-04 |
| `src/fileHistory.ts` | single-file | `src/fileHistory-test.md` | 1 | 8 | 80 | 2026-09-08 |
| `src/gitExecutable.ts` | single-file | `src/gitExecutable-test.md` | 1 | 1 | 6 | 2026-07-19 |
| `src/gitGraphView.ts` | single-file | `archive/src/gitGraphView-test/2026-05-02-pre-sharding-gitGraphView-test.md` | 1 | 17 | 60 | 2026-03-20 |
| `src/gitGraphView.ts` | sharded | `src/gitGraphView-test/INDEX.md` | 11 | 37 | 181 | 2026-10-07 |
| `src/gitGraphView.ts` | sharded | `src/gitGraphView-test/INDEX.md` | 11 | 38 | 183 | 2026-10-27 |
| `src/i18n.ts` | single-file | `src/i18n-test.md` | 1 | 2 | 11 | 2026-08-25 |
| `src/refValidation.ts` | single-file | `src/refValidation-test.md` | 1 | 1 | 19 | 2026-08-03 |
| `src/repoFileWatcher.ts` | single-file | `src/repoFileWatcher-test.md` | 1 | 10 | 74 | 2026-08-08 |
Expand All @@ -41,7 +41,8 @@
| `src/types.ts` | single-file | `src/types-test.md` | 1 | 8 | 93 | 2026-09-13 |
| `src/utils.ts` | single-file | `src/utils-test.md` | 1 | 6 | 26 | 2026-08-08 |
| `src/worktree.ts` | single-file | `src/worktree-test.md` | 1 | 1 | 17 | 2026-08-08 |
| `web/branchCleanupPanel.ts` | single-file | `web/branchCleanupPanel-test.md` | 1 | 6 | 51 | 2026-10-07 |
| `src/worktreePath.ts` | single-file | `src/worktreePath-test.md` | 1 | 3 | 25 | 2026-10-27 |
| `web/branchCleanupPanel.ts` | single-file | `web/branchCleanupPanel-test.md` | 1 | 7 | 53 | 2026-10-27 |
| `web/branchLabels.ts` | single-file | `web/branchLabels-test.md` | 1 | 1 | 17 | 2026-03-21 |
| `web/commitMenu.ts` | single-file | `web/commitMenu-test.md` | 1 | 12 | 53 | 2026-10-03 |
| `web/contextMenu.ts` | single-file | `web/contextMenu-test.md` | 1 | 10 | 77 | 2026-10-07 |
Expand All @@ -56,17 +57,17 @@
| `web/i18n.ts` | single-file | `web/i18n-test.md` | 1 | 3 | 11 | 2026-10-03 |
| `web/keyboardNavigation.ts` | single-file | `web/keyboardNavigation-test.md` | 1 | 4 | 54 | 2026-10-07 |
| `web/main.ts` | single-file | `archive/web/main-test/2026-03-22-pre-sharding-main-test.md` | 1 | 35 | 201 | 2026-03-12 |
| `web/main.ts` | sharded | `web/main-test/INDEX.md` | 19 | 61 | 450 | 2026-10-17 |
| `web/main.ts` | sharded | `web/main-test/INDEX.md` | 19 | 63 | 455 | 2026-10-27 |
| `web/messageHandler.ts` | single-file | `archive/web/messageHandler-test/2026-08-06-pre-sharding-messageHandler-test.md` | 1 | 12 | 41 | 2026-08-04 |
| `web/messageHandler.ts` | sharded | `web/messageHandler-test/INDEX.md` | 5 | 17 | 67 | 2026-09-29 |
| `web/messageHandler.ts` | sharded | `web/messageHandler-test/INDEX.md` | 5 | 18 | 68 | 2026-10-27 |
| `web/pathHighlight.ts` | single-file | `web/pathHighlight-test.md` | 1 | 3 | 21 | 2026-10-03 |
| `web/pathHighlightController.ts` | single-file | `web/pathHighlightController-test.md` | 1 | 2 | 17 | 2026-10-07 |
| `web/refMenu.ts` | single-file | `archive/web/refMenu-test/2026-08-03-pre-sharding-refMenu-test.md` | 1 | 14 | 74 | 2026-07-19 |
| `web/refMenu.ts` | sharded | `web/refMenu-test/INDEX.md` | 3 | 20 | 102 | 2026-10-03 |
| `web/refMenu.ts` | sharded | `web/refMenu-test/INDEX.md` | 3 | 21 | 104 | 2026-10-27 |
| `web/refOverflow.ts` | single-file | `web/refOverflow-test.md` | 1 | 5 | 85 | 2026-10-17 |
| `web/stashMenu.ts` | single-file | `web/stashMenu-test.md` | 1 | 8 | 30 | 2026-04-30 |
| `web/uncommittedMenu.ts` | single-file | `web/uncommittedMenu-test.md` | 1 | 1 | 3 | 2026-03-09 |
| `web/utils.ts` | single-file | `web/utils-test.md` | 1 | 5 | 31 | 2026-08-08 |
| `web/utils.ts` | single-file | `web/utils-test.md` | 1 | 4 | 20 | 2026-08-08 |
| `web/worktreeMenu.ts` | single-file | `web/worktreeMenu-test.md` | 1 | 1 | 21 | 2026-09-29 |

## Feature/Issue -> Perspectives (Reverse Lookup)
Expand Down Expand Up @@ -106,7 +107,7 @@
| Feature 020 (legacy-branding-cleanup) (aidd-spec-tasks-test) | `archive/src/gitGraphView-test/2026-05-02-pre-sharding-gitGraphView-test.md`, `src/gitGraphView-test/INDEX.md` |
| Feature 021 (loadMoreCommits-default-mismatch) (aidd-spec-tasks-test) | `archive/src/config-test/2026-05-17-pre-sharding-config-test.md`, `src/config-test/INDEX.md` |
| Feature 023 (worktree-dialog-defaults) (aidd-spec-tasks-test) | `web/commitMenu-test.md` |
| Feature 024 (worktree-path-normalize) (aidd-spec-tasks-test) | `web/commitMenu-test.md`, `web/utils-test.md` |
| Feature 024 (worktree-path-normalize) (aidd-spec-tasks-test) | `web/commitMenu-test.md` |
| Feature 026 (commit-detail-open-file) (aidd-spec-tasks-test) | `archive/src/config-test/2026-05-17-pre-sharding-config-test.md`, `archive/src/dataSource-test/2026-05-02-pre-sharding-dataSource-test.md`, `archive/web/messageHandler-test/2026-08-06-pre-sharding-messageHandler-test.md`, `src/config-test/INDEX.md`, `src/utils-test.md`, `web/main-test/INDEX.md`, `web/messageHandler-test/INDEX.md` |
| Feature 027 (commit-file-context-menu) (aidd-spec-tasks-test) | `web/fileMenu-test.md` |
| Feature 032 (context-menu-reorg) Task 7 | `archive/web/refMenu-test/2026-08-03-pre-sharding-refMenu-test.md`, `web/commitMenu-test.md`, `web/contextMenu-test.md`, `web/refMenu-test/INDEX.md`, `web/stashMenu-test.md` |
Expand Down Expand Up @@ -152,6 +153,7 @@
| Feature 061-05 (light-spec-plan) review fix | `web/contextMenu-test.md`, `web/dialogs-test.md`, `web/main-test/INDEX.md` |
| Feature 061-05 (light-spec-plan) user follow-up | `web/main-test/INDEX.md` |
| Feature 061-06 (light-spec-plan) | `web/main-test/INDEX.md`, `web/refOverflow-test.md` |
| Feature 062-01 (PR #114 follow-up) | `src/extension-test.md`, `src/gitGraphView-test/INDEX.md`, `src/worktreePath-test.md`, `web/branchCleanupPanel-test.md`, `web/main-test/INDEX.md`, `web/messageHandler-test/INDEX.md`, `web/refMenu-test/INDEX.md` |
| K2 demo-repository-config (light-spec-plan) | `scripts/readme-media/make-demo-repo-test.md` |
| light-spec-plan notes/features/042/spec.md | `src/avatarManager-test.md` |
| notes/features/044/memo-対応プラン.md | `web/dialogs-test.md` |
Expand Down
29 changes: 29 additions & 0 deletions docs/testing/perspectives/src/extension-test.md
Original file line number Diff line number Diff line change
Expand Up @@ -223,3 +223,32 @@
- Normal: TC-038

**失敗系/正常系比(煙感知器)**: 正常系1件(TC-038)、失敗系1件(TC-039)。本変更はハンドラの戻り値契約の追加のみで、失敗源は上表で網羅済みであることを確認した。

## S11: Configuration change for `worktreePathTemplate`

> Origin: Feature 062-01 (PR #114 follow-up)
> Added: 2026-10-27
> Status: active
> Supersedes: -
> Signature: the `onDidChangeConfiguration` handler registered by `activate()`
> Target Path: `src/extension.ts` (the `git-keizu.worktreePathTemplate` branch of the configuration change handler)
> Test File: `tests/src/extension.test.ts`

Extends the routing of S4. A change to `git-keizu.worktreePathTemplate` reaches only the open panel's `notifyWorktreePathChanged()` (`src/gitGraphView-test/03-worktree-actions-01.md` S44); it must not touch the status bar item or Recent actions. Fixture: S4's captured handler and `createConfigurationChangeEvent`, with `GitKeizuView.currentPanel` replaced by a mock that has `notifyWorktreePathChanged`.

| Case ID | Input / Precondition | Perspective (Normal / Validation / Exception / External / Boundary / Type) | Expected Result | Notes |
| ------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ | ---------------------------------------- |
| TC-040 | `affectsConfiguration` is `true` only for `git-keizu.worktreePathTemplate`, panel open | Normal - routed to the panel only | `notifyWorktreePathChanged` is called once; `notifyShowRecentActionsChanged` and the status bar `refresh` are not called | No-panel case shares S4 TC-023's pattern |

### Failure-source inventory (include-or-justify) — S11

| Failure source | Case or reason for exclusion |
| ---------------------------------------------- | -------------------------------------------------------------------------------------------------------- |
| Setting change not forwarded | TC-040 |
| Unrelated refresh (status bar, Recent actions) | TC-040 |
| No panel open | not covered for this key (the same optional-chaining call is fixed for `showRecentActions` by S4 TC-023) |
| Exception / External / Type | excluded (the handler only calls into the panel) |

### Test mapping — S11

`tests/src/extension.test.ts`: TC-040 `TC-040: notifies the open panel when worktreePathTemplate changes`, next to S4's TC-021 to TC-023.
Original file line number Diff line number Diff line change
Expand Up @@ -163,3 +163,34 @@ S15 TC-051、S16 TC-053〜TC-058は維持する。`mockDataSource`は`removeWork
- External: TC-409
- Boundary: TC-402
- Type: TC-401、TC-403〜TC-407

## S44: Worktree path settings sent to the webview

> Origin: Feature 062-01 (PR #114 follow-up)
> Added: 2026-10-27
> Status: active
> Supersedes: -
> Signature: `viewState.worktreePath` in `getHtmlForWebview()` / `public notifyWorktreePathChanged(): void`, both built by `currentWorktreePathViewState()`
> Target Path: `src/gitGraphView.ts` (`currentWorktreePathViewState`, `notifyWorktreePathChanged`, the `viewState` object of `getHtmlForWebview`)
> Test File: `tests/src/gitGraphView.test.ts`

The webview has no Node `os` / `process`, so the host sends what the path resolver needs: the template from `git-keizu.worktreePathTemplate`, the home directory, the platform, the process working directory and the Windows per-drive working directories (`src/worktreePath-test.md` S3). The same value goes into the initial `viewState` and into the `setWorktreePath` message sent when the setting changes (`src/extension-test.md` S11), and the message does not rebuild the HTML. The setting count and the `worktreePath` key are also fixed by `08-keyboard-accessibility-01.md` S42 TC-417. Fixture: the shared panel mocks of this file with the default `worktreePathTemplate`.

| Case ID | Input / Precondition | Perspective (Normal / Validation / Exception / External / Boundary / Type) | Expected Result | Notes |
| ------- | --------------------------------------------------------------------- | -------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------- |
| TC-419 | Create the panel and parse `viewState` from the HTML | Normal - initial value | `viewState.worktreePath` equals `{ template: "${repoPath}/../${repoName}-${branch}", homeDir: homedir(), platform: "win32" or "posix" from process.platform, cwd: process.cwd(), driveCwd: windowsDriveDirectories(process.env) }` | - |
| TC-420 | Open panel, `postMessage` cleared, then `notifyWorktreePathChanged()` | Normal - runtime update without reload | `postMessage` is called once with `{ command: "setWorktreePath", worktreePath: <same value as TC-419> }` and `webview.html` is unchanged | Same pattern as S20 for Recent actions |

### Failure-source inventory (include-or-justify) — S44

| Failure source | Case or reason for exclusion |
| ---------------------------------------------- | ---------------------------------------------------------------------------------------------------- |
| A field the resolver needs is missing or wrong | TC-419, TC-420 |
| Setting change regenerates the webview HTML | TC-420 |
| No panel open when the setting changes | excluded (`src/extension.ts` calls it with optional chaining; see `src/extension-test.md` S4 TC-023) |
| Windows values on a Windows host | excluded (CI runs on Linux; the resolver side is `src/worktreePath-test.md` S3) |
| Exception / External / Type | excluded (no throw path; `WorktreePathViewState` is checked by `pnpm run typecheck`) |

### Test mapping — S44

`tests/src/gitGraphView.test.ts`: TC-419 `includes the worktree path template in viewState (TC-419)` in describe `GitKeizuView merge/cherry-pick handler and viewState dialogDefaults (S13)`; TC-420 `posts setWorktreePath with the current template without regenerating HTML (TC-420)` in describe `GitKeizuView notifyShowRecentActionsChanged runtime sync`.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
| TC-414 | `#commitTable` の属性 | Normal - 一覧の名前 | `aria-label` が `hostT("Commit history")` の戻り値 | K44 / K45 |
| TC-415 | `#content` / `#scrollContainer` 周辺の通知要素 | Normal - 分離した status 要素 | `role="status"` と `aria-live="polite"` を持つ要素が 1 個あり、名前が `hostT("Git Keizu status")`、`#commitGraph` / `#commitTable` の子孫ではなく、`#commitGraph` と `#commitTable` 自体に `aria-live` が無い | K44 / R4.8「グラフ全体の再描画をlive領域として読み直させない」 |
| TC-416 | 生成 HTML 全体の `id` 集合を変更前と比較 | Validation - 既存 ID の維持 | 既存 ID がすべて残り(`repoSelect` / `branchSelect` / `authorSelect` / `showRemoteBranchesCheckbox` / `branchCleanupBtn` / `searchBtn` / `fetchBtn` / `currentBtn` / `refreshBtn` / `branchCleanupPanel` / `scrollContainer` / `scrollShadow` / `content` / `commitGraph` / `commitTable` / `footer` / `dialogBacking` / `dialog`)、重複 ID が 0 件 | Task 9「既存IDを維持」 |
| TC-417 | `viewState` の JSON と `package.json` の `contributes.configuration` | Validation - 設定・プロトコルの追加なし | `viewState` のキーに `worktreePath` が含まれ、`git-keizu.*` の設定項目数は 33(`worktreePathTemplate` を含む) | §3.1 / R6 |
| TC-417 | `viewState` の JSON と `package.json` の `contributes.configuration` | Validation - viewState キーと設定項目数の固定 | `viewState` のキーに `worktreePath` が含まれ、`git-keizu.*` の設定項目数は 33(`worktreePathTemplate` を含む) | §3.1 / R6 |

### 失敗源インベントリ(include-or-justify)— Feature 061-05 追加分(S42)

Expand Down
9 changes: 5 additions & 4 deletions docs/testing/perspectives/src/gitGraphView-test/INDEX.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

> Source: `src/gitGraphView.ts`
> Storage Mode: sharded
> Generated: 2026-10-07T00:00:00Z
> Generated: 2026-10-27T00:00:00Z
> Language: TypeScript
> Test Framework: Vitest
> Total Shards: 11
> Total Sections: 37
> Total Cases: 181
> Total Sections: 38
> Total Cases: 183

## Shards

Expand All @@ -18,7 +18,7 @@
| 01-message-routing-03.md | message-routing | 3 | 26 | 2026-08-06 |
| 02-state-lifecycle-01.md | state-lifecycle | 12 | 47 | 2026-09-12 |
| 02-state-lifecycle-02.md | state-lifecycle | 1 | 1 | 2026-09-12 |
| 03-worktree-actions-01.md | worktree-actions | 5 | 34 | 2026-09-13 |
| 03-worktree-actions-01.md | worktree-actions | 6 | 36 | 2026-10-27 |
| 04-context-menu-recent-actions-01.md | context-menu-recent-actions | 2 | 3 | 2026-05-10 |
| 05-branch-cleanup-01.md | branch-cleanup | 1 | 15 | 2026-08-25 |
| 06-file-history-01.md | file-history | 1 | 12 | 2026-09-08 |
Expand Down Expand Up @@ -54,6 +54,7 @@
| Feature 057 (multi-repo-single-folder-workspace) issue #49 | 02-state-lifecycle-01.md |
| Feature 057 (multi-repo-single-folder-workspace) issue #49 PR #60 レビュー指摘 | 02-state-lifecycle-01.md, 02-state-lifecycle-02.md |
| Feature 061-05 (light-spec-plan) | 08-keyboard-accessibility-01.md |
| Feature 062-01 (PR #114 follow-up) | 03-worktree-actions-01.md |
| test-plan (既存コード網羅) | 01-message-routing-01.md |
| フェーズ2 修正 M5 (message-handler-try-finally-unmute) | 02-state-lifecycle-01.md |
| フェーズ2 修正 M9/M10 (view-diff-resolve-head) | 01-message-routing-02.md |
Expand Down
Loading
Loading