You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@texera.apache.org by "mengw15 (via GitHub)" <gi...@apache.org> on 2026/07/22 03:27:40 UTC
[I] add unit test coverage for MenuComponent button and toggle logic [texera]
mengw15 opened a new issue, #6746:
URL: https://github.com/apache/texera/issues/6746
### Task Summary
`MenuComponent` sits at codecov ~70% (81 uncovered lines) — the toolbar's button-behavior, toggle, and version-display logic is largely untested. Extend the spec, mocking the injected services. jsdom/Vitest; see `frontend/TESTING.md`.
### Behavior to add
**MenuComponent** (`frontend/src/app/workspace/component/menu/menu.component.ts`, codecov ~70% — EXTEND)
Inject doubles for the workflow/action services (`WorkflowActionService`, `WorkflowWebsocketService`, `ExecuteWorkflowService`, etc. — use `vi.fn()` / existing stubs; no real websocket). Cover:
- Run-button state: `getRunButtonBehavior` / `applyRunButtonBehavior` — assert the computed behavior (run / pause / resume / kill) for representative execution states; `hasOperators` reflects the graph.
- Toggles: `toggleGrid` / `toggleStatus` / `toggleRegion` / `toggleNumWorkers` — each flips its flag and/or calls the corresponding service.
- Click handlers: `onClickAutoLayout` / `onClickDeleteAllOperators` / `onClickCreateNewWorkflow` / `onClickExportWorkflow` / `onClickExportExecutionResult` / `onClickGenerateReport` / `onClickResetPanels` / `onClickClosePanels` / `onClickAddCommentBox` — assert each delegates to the expected service/emitter.
- Name editing: `onWorkflowNameChange` / `adjustWorkflowNameWidth` — assert the persisted name / width update.
Out of scope: the `registerXxxHandler` subscription wiring and `runWorkflow` / `handleKill` / `handleCheckpoint` execution side-effects if they require a live websocket — scope to the pure/delegating branches.
### Task Type
- [ ] Refactor / Cleanup
- [ ] DevOps / Deployment / CI
- [x] Testing / QA
- [ ] Documentation
- [ ] Performance
- [ ] Other
--
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: notifications-unsubscribe@texera.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] add unit test coverage for MenuComponent button and toggle logic [texera]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #6746:
URL: https://github.com/apache/texera/issues/6746#issuecomment-5041507405
<!-- texera:template-compliance -->
👋 Thanks for opening this issue, @mengw15!
It looks like the issue description doesn't quite follow our template yet:
- This issue doesn't appear to use one of our templates (Bug, Feature, or Task). Please open it using a template so the required details are captured.
Filling out the template helps reviewers understand and triage your contribution faster. Please edit the description to complete it. This message will disappear automatically once the template is followed.
You can find the template prompts by editing the description, or see [CONTRIBUTING.md](https://github.com/apache/texera/blob/main/CONTRIBUTING.md) for the full contribution flow.
--
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: notifications-unsubscribe@texera.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] add unit test coverage for MenuComponent button and toggle logic [texera]
Posted by "aglinxinyuan (via GitHub)" <gi...@apache.org>.
aglinxinyuan closed issue #6746: add unit test coverage for MenuComponent button and toggle logic
URL: https://github.com/apache/texera/issues/6746
--
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: notifications-unsubscribe@texera.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org