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

   ### Task Summary
   
   Three small frontend components, each 4 lines of gap:
   
   | File | Coverage |
   |---|---|
   | `left-panel/time-travel/time-travel.component.ts` | 92.3% — 4 missed of 52 
|
   | `dashboard/.../feedback/feedback.component.ts` | 85.2% — 4 missed of 27 |
   | `dashboard/.../feedback/feedback.component.html` | 83.3% — 4 missed of 24, 
and **0 of its 2 functions covered** |
   
   The template's function counter is the signal: zero percent of its functions 
are entered, which an 83% line figure hides.
   
   **One file must be left alone.** `repeat-dnd.component.html` line 48 is the 
remove button's `[disabled]="field.templateOptions?.disabled"`, and issue 
**#7431** records that the enclosing `*ngFor` shadows the outer `field`, so it 
never disables. Do not write a test that pins that arm — report it instead. 
Assertions on the *add* button are fine.
   
   Also note `port-property-edit-frame.component.ts` looks like a candidate and 
is worth **zero**: two of its three residual lines are dead Quill config and 
the third is unreachable in practice.
   
   Traps, each measured:
   
   1. **The time-travel poller subscription is created in `ngOnInit`**, i.e. at 
the existing spec's `fixture.detectChanges()` in `beforeEach`, which runs 
*outside* `fakeAsync` — timers scheduled in the real zone cannot be fired by 
`tick()`. New tests must call `TestBed.createComponent` and `detectChanges` 
**inside** the `fakeAsync` body.
   2. **`timer(0, 5000)` registers as a zone periodic task**, so leaving it 
pending fails the test with "periodic timer(s) still in the queue". End with 
`fixture.destroy()` and/or `discardPeriodicTasks()`.
   3. **The existing spec's outer `beforeEach` deliberately stubs 
`getWorkflowMetadata` to `undefined`** so the poller sees no wid. New poller 
tests need their own fixture in their own `describe` — overriding that stub in 
the shared `beforeEach` would start firing real requests in the other 18 tests.
   4. **The builder typechecks every spec at bundle time, and one type error 
aborts the whole run with no lcov.** Note `keyCode`/`which` *are* in TS's 
`KeyboardEventInit`, so a `@ts-expect-error` there is itself an error 
(`TS2578`).
   5. **Two obvious tests here are vacuous as first written.** An 
`extractError` test survives an operand exchange unless the fixture carries 
*both* `error.message` and `message`; a nested-`fieldGroup` test survives 
`[field]="subField"` → `[field]="field"` unless it asserts the rendered 
formly-field's own `field.key` rather than counting elements.
   6. A fresh worktree has no `frontend/node_modules` — do a **real install** 
(`node .yarn/releases/yarn-4.14.1.cjs install --immutable --inline-builds`, 
~35s off the Berry cache), never a junction from the main checkout.
   
   ### 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