Skip to content

test(node): raise vitest hook timeout to 15s - #495

Merged
pratyush618 merged 1 commit into
ByteVeda:masterfrom
stromanni:fix/node-dashboard-hook-timeout
Jul 22, 2026
Merged

test(node): raise vitest hook timeout to 15s#495
pratyush618 merged 1 commit into
ByteVeda:masterfrom
stromanni:fix/node-dashboard-hook-timeout

Conversation

@stromanni

@stromanni stromanni commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

Problem

The Windows Node smoke job on master is flaky: test/dashboard/inspectRoutes.test.ts > 404s a replay of an unknown job fails with Hook timed out in 10000ms. (run)

The failing hook is the dashboard suite's beforeEach, which seeds an admin session via seedAdminAndSession — a PBKDF2 hash at 600k iterations. On a contended CI runner that can exceed vitest's 10s default hook timeout. testTimeout was already raised to 15s, but hookTimeout was left at the default, so the setup hook had less headroom than the test it sets up.

Fix

Set hookTimeout: 15000 in vitest.config.ts to match testTimeout. One line, covers every dashboard test that seeds a session (not just the one that happened to trip this run).

Unrelated to the webhook store change in #494 — this hook flake predates it and affects the whole dashboard suite.

Summary by CodeRabbit

  • Tests
    • Increased the test hook timeout to improve reliability in slower CI environments.

Dashboard beforeEach hooks seed a PBKDF2 session that can outrun the 10s default on slow CI runners.
@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: d9ef307f-e646-4394-9144-632890d2a609

📥 Commits

Reviewing files that changed from the base of the PR and between bc8e14c and d226bf1.

📒 Files selected for processing (1)
  • sdks/node/vitest.config.ts

📝 Walkthrough

Walkthrough

The Node SDK Vitest configuration increases the hook timeout to 15,000 milliseconds and adds a comment describing its purpose for slower CI dashboard hook seeding.

Changes

Vitest timeout configuration

Layer / File(s) Summary
Increase Vitest hook timeout
sdks/node/vitest.config.ts
Sets test.hookTimeout to 15000 and documents the CI-related rationale.

Estimated code review effort: 1 (Trivial) | ~2 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: increasing Vitest hook timeout to 15 seconds for node tests.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@kartikeya-27
kartikeya-27 requested a review from pratyush618 July 22, 2026 05:50
@pratyush618
pratyush618 merged commit 1ac500b into ByteVeda:master Jul 22, 2026
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants