mengw15 opened a new issue, #6389:
URL: https://github.com/apache/texera/issues/6389

   ### Task Summary
   
   
`frontend/src/app/dashboard/component/user/user-computing-unit/user-computing-unit-list-item/user-computing-unit-list-item.component.ts`
 (codecov ~9%, no spec) — add a behavior-focused Vitest spec (TestBed + 
`detectChanges()`). See `frontend/TESTING.md` and the `user-dataset-list-item` 
spec (#5230) for the pattern; mock `ComputingUnitService`, 
`NotificationService`, `ComputingUnitStatusService`, 
`ComputingUnitActionsService`.
   
   ### Behavior to cover
   
   - `should create` — instantiates; `fixture.detectChanges()` renders the 
template
   - `entry` @Input / `unit` getter — expose the bound value
   - `confirmUpdateUnitName(cuid, newName)`:
     - invalid name (via `validateName`) -> 
`notificationService.error(validationError)` + cancels editing; no rename call
     - valid -> calls `computingUnitService.renameComputingUnit(cuid, 
trimmedName)`; on success -> `notificationService.success("Successfully renamed 
computing unit")`, updates `entry.computingUnit.name` when the cuid matches, 
calls `refreshComputingUnitList()`; on error -> 
`notificationService.error("Failed to rename computing unit: ...")`
   - `onClickOpenShareAccess(cuid)` -> calls 
`computingUnitActionsService.openShareAccessModal(cuid, false)`
   - `@Output() deleted` — emits on the delete flow
   
   ### 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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to