mengw15 opened a new pull request, #6557: URL: https://github.com/apache/texera/pull/6557
### What changes were proposed in this PR? Extends three existing frontend specs to cover previously untested methods (all Vitest; no production code changed). **`WorkflowCompilingService`** (+9 tests) — `getWorkflowCompilationState`, `getWorkflowCompilationErrors` (empty while succeeded/uninitialized, surfaces operator errors when failed), `getCompilationStateInfoChangedStream` (replays the latest state), `getOperatorOutputSchemaMap`, `getPortInputSchema`, and `getOperatorInputAttributeType`. The private compilation-state snapshot is set directly and the port-lookup delegates are spied so each getter's own logic is exercised. **`ListItemComponent`** (+8 tests) — `onEditName`, `onEditDescription` (opens the edit modal and applies / closes the change; no-op when not editable), `onCheckboxChange`, `toggleLike` (like / unlike success paths + the no-user guard), and `openDetailModal` (opens the modal and bumps the view count). `NzModalService` and `HubService` are spied. **`DownloadService`** (+3 tests) — `exportWorkflowResultToDataset` (POST body / headers, plus the kubernetes `?cuid=` URL branch, via `HttpTestingController`) and `exportWorkflowResultToLocal` (builds and submits the hidden form carrying the request + token, then cleans up). The download form's `submit` and the cleanup `setTimeout` are stubbed so no real navigation or leaked timer occurs. ### Any related issues, documentation, discussions? Closes #6552 ### How was this PR tested? Extended unit tests, run locally in `frontend/` (all green; each spec's failure path was verified by breaking a new assertion to confirm it goes red): ``` ng test --watch=false --include src/app/workspace/service/compile-workflow/workflow-compiling.service.spec.ts # 16 passed ng test --watch=false --include src/app/dashboard/component/user/list-item/list-item.component.spec.ts # 20 passed ng test --watch=false --include src/app/dashboard/service/user/download/download.service.spec.ts # 17 passed (1 pre-existing skip) prettier --write <specs> # clean eslint <specs> # clean ``` All collaborators are stubbed, so the suite makes no network calls, opens no real modal, and triggers no real download (see `frontend/TESTING.md`). ### Was this PR authored or co-authored using generative AI tooling? Generated-by: Claude Code (Opus 4.8 [1M context]) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
