|
| 1 | +# Project Workspace Contract Rename Validation |
| 2 | + |
| 3 | +PR: PR_26152_079-project-workspace-contract-rename |
| 4 | +Date: 2026-06-02 |
| 5 | + |
| 6 | +## Scope |
| 7 | + |
| 8 | +- Continued from PR_26152_078. |
| 9 | +- Renamed runtime-only Workspace terminology to Project Workspace. |
| 10 | +- Updated contracts, contract tests, docs/specs, and required reports only. |
| 11 | +- No database implementation, authentication implementation, runtime UI, page, CSS, or HTML changes were made. |
| 12 | + |
| 13 | +## Contract Rename |
| 14 | + |
| 15 | +- The previous runtime-only contract file was renamed to `src/shared/contracts/projectWorkspaceRuntimeContract.js`. |
| 16 | +- The matching runtime-only contract test was renamed to `tests/shared/ProjectWorkspaceRuntimeContract.test.mjs`. |
| 17 | +- The runtime-only contract terminology was renamed to Project Workspace Runtime Contract. |
| 18 | +- Project Workspace is the active runtime working context for a Project. |
| 19 | + |
| 20 | +## Project Workspace Rules |
| 21 | + |
| 22 | +- Project Workspace is runtime-only. |
| 23 | +- Project Workspace does not persist tool payloads. |
| 24 | +- Project Workspace does not own saved tool state. |
| 25 | +- Project Workspace does not duplicate project storage. |
| 26 | +- Project Workspace does not duplicate tool state storage. |
| 27 | +- Project Workspace recovery points to Tool State recovery. |
| 28 | + |
| 29 | +## Data Ownership |
| 30 | + |
| 31 | +- Project = persisted DB container. |
| 32 | +- Project Workspace = current runtime working context for the Project. |
| 33 | +- Tool State = persisted DB record for one tool. |
| 34 | +- Manifest = portable export/import format. |
| 35 | + |
| 36 | +## Docs |
| 37 | + |
| 38 | +- Added `docs/dev/specs/PROJECT_WORKSPACE_RUNTIME_CONTRACT.md`. |
| 39 | +- Updated `docs/dev/specs/TOOL_LAUNCH_SSOT.md` to use Project Workspace terminology for prior runtime launch state. |
| 40 | + |
| 41 | +## Validation Commands |
| 42 | + |
| 43 | +Targeted contract tests: |
| 44 | + |
| 45 | +```powershell |
| 46 | +$contractTests = @( |
| 47 | + 'tests/shared/ProjectWorkspaceRuntimeContract.test.mjs', |
| 48 | + 'tests/shared/ToolStateContract.test.mjs', |
| 49 | + 'tests/shared/ProjectContract.test.mjs', |
| 50 | + 'tests/shared/IdentityPermissionsContract.test.mjs' |
| 51 | +) |
| 52 | +$toolContractTests = Get-ChildItem -Path tests/shared/tools -Filter '*.test.mjs' | Sort-Object Name | ForEach-Object { $_.FullName } |
| 53 | +node ./scripts/run-node-test-files.mjs $contractTests $toolContractTests |
| 54 | +``` |
| 55 | + |
| 56 | +Result: PASS, `40/40 targeted node test file(s) passed`. |
| 57 | + |
| 58 | +Static checks: |
| 59 | + |
| 60 | +```powershell |
| 61 | +git diff --check -- src/shared/contracts tests/shared docs/dev/specs docs/dev/reports/project_workspace_contract_rename_validation.md docs/dev/commit_comment.txt |
| 62 | +git diff --name-only -- '*.css' '*.html' |
| 63 | +Test-Path src/shared/contracts/workspaceRuntimeContract.js |
| 64 | +Test-Path tests/shared/WorkspaceRuntimeContract.test.mjs |
| 65 | +rg -P "^# Workspace|^- Workspace|^Workspace(?! Manager)|^- workspace|^workspace" -n src/shared/contracts/projectWorkspaceRuntimeContract.js tests/shared/ProjectWorkspaceRuntimeContract.test.mjs docs/dev/specs/PROJECT_WORKSPACE_RUNTIME_CONTRACT.md docs/dev/specs/TOOL_LAUNCH_SSOT.md docs/dev/reports/project_workspace_contract_rename_validation.md |
| 66 | +rg '"workspaceState"' -n src/shared/contracts/projectWorkspaceRuntimeContract.js tests/shared/ProjectWorkspaceRuntimeContract.test.mjs |
| 67 | +``` |
| 68 | + |
| 69 | +## Expected Results |
| 70 | + |
| 71 | +- PASS: Project Workspace contract tests validate terminology and behavior remain unchanged. |
| 72 | +- PASS: Project Workspace rejects old standalone workspace storage fields such as `workspaceState`. |
| 73 | +- PASS: Tool State remains the saved editing source. |
| 74 | +- PASS: Project, Identity/Permissions, and Tool contract tests remain compatible. |
| 75 | +- PASS: no runtime/UI/CSS/HTML files changed. |
| 76 | +- PASS: no repo-wide or samples tests run. |
| 77 | + |
| 78 | +## Skipped |
| 79 | + |
| 80 | +- Repo-wide tests were not run. |
| 81 | +- Samples tests were not run. |
| 82 | +- Runtime/UI validation was not run because this PR only changes contracts, contract tests, docs/specs, and reports. |
0 commit comments