fix: sense-list.test.ts 5 tests failing — senseTriggerLabels is not a function #141

Closed
opened 2026-04-25 09:03:17 +00:00 by xiaoju · 0 comments
Owner

Bug

packages/cli/src/__tests__/sense-list.test.ts has 5 failing tests on main:

❯ src/__tests__/sense-list.test.ts (22 tests | 5 failed)
  × parses senses from valid nerve.yaml
  × always sets lastSignalTimestamp to null (static fallback)
  × populates throttle and timeout from config
  × resolves with { ok: true, senses: [] } when daemon returns empty list
  × resolves with populated senses array

Errors

3 tests in sensesFromConfig:

TypeError: senseTriggerLabels is not a function

2 tests in listSensesViaDaemon:

AssertionError: expected { ok: false, …(1) } to deeply equal { ok: true, senses: [] }

Likely Cause

senseTriggerLabels was likely renamed/removed/refactored in core but the test still imports the old name. The daemon client tests may have a similar stale mock or response shape mismatch.

Files

  • packages/cli/src/__tests__/sense-list.test.ts
  • Possibly packages/core/src/ (source of truth for senseTriggerLabels)
  • Possibly packages/cli/src/commands/sense-list.ts or similar

小橘 🍊(NEKO Team)

## Bug `packages/cli/src/__tests__/sense-list.test.ts` has 5 failing tests on main: ``` ❯ src/__tests__/sense-list.test.ts (22 tests | 5 failed) × parses senses from valid nerve.yaml × always sets lastSignalTimestamp to null (static fallback) × populates throttle and timeout from config × resolves with { ok: true, senses: [] } when daemon returns empty list × resolves with populated senses array ``` ### Errors **3 tests in `sensesFromConfig`:** ``` TypeError: senseTriggerLabels is not a function ``` **2 tests in `listSensesViaDaemon`:** ``` AssertionError: expected { ok: false, …(1) } to deeply equal { ok: true, senses: [] } ``` ### Likely Cause `senseTriggerLabels` was likely renamed/removed/refactored in core but the test still imports the old name. The daemon client tests may have a similar stale mock or response shape mismatch. ## Files - `packages/cli/src/__tests__/sense-list.test.ts` - Possibly `packages/core/src/` (source of truth for `senseTriggerLabels`) - Possibly `packages/cli/src/commands/sense-list.ts` or similar 小橘 🍊(NEKO Team)
This repo is archived. You cannot comment on issues.
No Label
1 Participants
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: uncaged/nerve#141